Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 No Autocomplete For #defined pointers/references.

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
gunvulture Posted - Jun 01 2006 : 1:57:26 PM
I use #defines to provide easy access to systems in my engine. However, autocomplete flat out doesn't work on them. Here is an example:

template <typename T>
class Singleton
{
<snip>
static T& GetSingletonRef(Context* i_pForFutureUse) { return *s_pSingleton; }
};

class EngineManager : public Singleton<EngineManager>
{ <snip> };

#define g_EngineManager EngineManager::GetSingletonRef(0)

Doing "g_EngineManager." shows no members at all.

Doing "g_EngineManager.SomeFunction(" shows a tooltip saying "#define g_EngineManager EngineManager::GetSingletonRef(0)"

Using VAX build 1445.
3   L A T E S T    R E P L I E S    (Newest First)
gunvulture Posted - Jun 04 2006 : 5:35:53 PM
Ah that appears to be me last time as well. I forgot I already mentioned it, heh.
swinefeaster Posted - Jun 02 2006 : 5:23:01 PM
This is also considered bad programming practice by most developers... you should use polymorphism for this.

Regards,

swine
feline Posted - Jun 01 2006 : 5:47:56 PM
unfortunately VA does not try to support this sort of thing. it is possible to do some very strange things with macro's, so it is easy to imagine just how complicated this would quickly become.

see supports answer here:
http://forum.wholetomato.com/forum/topic.asp?TOPIC_ID=4253

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000