Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 VAX not recognizing symbols

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
mwh Posted - Aug 07 2014 : 05:55:46 AM
Hello,
I had some problems with VAX recognizing symbols before, but after I set up my computer new, the problems had temporarily gone. Now they are back. But this time I hope I can provide more information. I have the following:

ShapeBase.h

#pragma once
class ShapeBase {};

AreaShapeBase.h

#pragma once
#include "ShapeBase.h"
class AreaShapeBase : public ShapeBase {};

EllipseShape.h

#pragma once
#include "DataObjectsLib.h"
#include "AreaShapeBase.h"
class DATAOBJECTS_EXPORT EllipseShape : public AreaShapeBase {};

The class symbol EllipseShape is not recognized by VAX. (Find Reference ==> "Find Reference is not available because the symbol is unrecognized.")

The culprit is perhaps the macro DATAOBJECTS_EXPORT defined in DataObjectsLib.h:

#pragma once

#ifdef _LINUX

	#define DATAOBJECTS_EXPORT __attribute((visibility("default")))

#else // Windows

	#undef DATAOBJECTS_EXPORT
	#ifdef DATAOBJECTS_LIB
		#define DATAOBJECTS_EXPORT __declspec(dllexport)
	#else
		#define DATAOBJECTS_EXPORT __declspec(dllimport)
	#endif

#endif


If I delete the Linux stuff and use the windows stuff only, EllipseShape is recognized and everything works fine. Unfortunatly, we need the Linux stuff. ;-)

More information:

  • If I add the va_stdafx.h with a simple definition of the macro, it works with this simple example. But the real code is much more complex and with the real code the va_stdafx.h does not help.

  • I have set the registry keys so that deep macro parsing is enabled.

  • System: Win7 x64, VS2008 (Version 9.0.30729.4108), VAX 10.8.2043.0

I hopy this information is helpful.
Marc
6   L A T E S T    R E P L I E S    (Newest First)
feline Posted - Aug 26 2014 : 2:46:01 PM
Thank you for the update. I am not actually sure how VA will handle multiple va_stdafx.h files for the same solution, but it will certainly make tracking down the cause of an event more tricky, since there will be several files to consider.

Hopefully this will stay fixed, and obviously, if you have any more problems, please let me know, and I will do everything I can to help.
mwh Posted - Aug 26 2014 : 01:34:14 AM
Hello feline.

I am not sure, if using the simple macro form did the trick or if it was something else that I changed, but it seems that the problem is gone now. I tried reinstalling VAX, rebuilding databases (again and again), deleting databases manually and - perhaps the real reason why it did not work - deleted two other va_stdafk.h files that were deeper in my project file system... Now I have only one, at the sln file. This and using the simple macro form seems to solve my problem.

Thank you. :-)
feline Posted - Aug 25 2014 : 10:06:30 AM
Has the simple macro in the va_stdafx.h file fixed this problem for you? Hopefully so, but if not then I will keep on looking at this with you, to try and find a good solution.

I would have expected changing the order of the #defines for Linux and Windows to have helped, strange that it didn't.
mwh Posted - Aug 25 2014 : 12:36:28 AM
I use the simple macro form in va_stdafk.h as you described: #define DATAOBJECTS_EXPORT

Exchanging the #ifdef with #ifndef as you proposed did not help unfortunatly.
feline Posted - Aug 08 2014 : 8:43:06 PM
Which simple version of the macro have you tried in the va_stdafx.h file? This is where I would normally start, trying to fix this. Have you tried an "empty" macro in the va_stdafx.h file? Specifically:

#define DATAOBJECTS_EXPORT

The other obvious thing to try is to change the order of the defines in the "DataObjectsLib.h" file, to become:

#ifndef _LINUX  // Windows

	#undef DATAOBJECTS_EXPORT
	#ifdef DATAOBJECTS_LIB
		#define DATAOBJECTS_EXPORT __declspec(dllexport)
	#else
		#define DATAOBJECTS_EXPORT __declspec(dllimport)
	#endif

#else // Linux

	#define DATAOBJECTS_EXPORT __attribute((visibility("default")))

#endif

if you re-order the macros, a symbol database rebuild might be a good idea, just to make sure that VA has had a chance to catch up with this.
mwh Posted - Aug 07 2014 : 05:58:31 AM
I forgot one information.
If I set the macro before the class keyword, all works fine as well, even with the nested #ifdef for the Linux stuff.

This does work:

DATAOBJECTS_EXPORT class EllipseShape : public AreaShapeBase {};


This does not work:

class DATAOBJECTS_EXPORT EllipseShape : public AreaShapeBase {};


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