Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Technical Support
 Issue with "double" getting undefined

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
diarrhio Posted - Apr 28 2010 : 3:14:05 PM
Not sure if the subject really describes the problem, but whatever.

Anyways, we have some third party library (Matlab) which has a section of code which looks like this:

#ifdef NO_FLOATS
# define double double_not_allowed
# define float  float_not_allowed
#endif /*NO_FLOATS*/


We don't have NO_FLOATS defined anywhere, so I am assuming that VAX will simply ignore the #define of double. This is not the case, unfortunately.

All double variables in our code, all methods that return a double become unrecognized by VAX. Actually, they aren't totally unrecognized. Here is what I see on some double local variable I declare:

double someValue = someOtherDoubleValue;


someValue in the line above will simply be uncolored. However, subsequent references to someValue will be underlined with red as unrecognized. Oddly, if you hover over any reference to someValue (which is underlined as red), you will see the tooltip properly describe the variable (i.e. the tooltip will say "double someValue")

I am using latest version of VAX, 182. This issue has been around for a loooooong time though. Finally got sick of it enough to say something :)
12   L A T E S T    R E P L I E S    (Newest First)
diarrhio Posted - Jun 15 2010 : 1:20:22 PM
Just confirmed that this has been fixed. Thank you!
diarrhio Posted - Jun 14 2010 : 12:48:54 PM
Excellent!
sean Posted - Jun 12 2010 : 03:13:09 AM
The internal fix referred to by support was case=43586.
case=43586 is fixed in build 1827.
support Posted - Jun 03 2010 : 2:14:08 PM
We have an internal fix for this (undergoing testing). In the meantime, adding the following lines to VA's stdafx.h file should fix the problem.

# define double signed double,
# define float signed float,

http://docs.wholetomato.com?W302
accord Posted - May 03 2010 : 3:34:45 PM
Actually I did not used the trial to reproduce this. Their process of getting a trial is not as trivial as I thought.
However, based on the information you had provided, I could create a simplified environment and saw the same problems as you.
diarrhio Posted - May 03 2010 : 3:20:53 PM
Thanks for the quick update! And I'm glad you were able to reproduce.
accord Posted - May 03 2010 : 3:19:57 PM
Apologies for the delay in getting back to you about this.

I got the screenshots, thank you. I tried several ways to stop double from being overwritten but did not find any, I've asked the developers about this.
I'll get back to you.
diarrhio Posted - May 03 2010 : 11:27:20 AM
I submitted a ticket last week. Any word on this?

Thanks
accord Posted - Apr 29 2010 : 12:56:38 PM
You can send the screenshot to us via this form:

http://www.wholetomato.com/support/contact.asp

Please include the URL of this thread in the description so we can match it up.

Are you using this MATLAB?
http://www.codeproject.com/KB/cpp/matlab_cpp.aspx
diarrhio Posted - Apr 29 2010 : 11:59:51 AM
Hmmmm. That didn't seem to help.

I copied the StdAfx.h file from the Program Settings location to %DOCS&SETTINGS%\\Application Data\\VisualAssist\\Misc\\ and added the two lines to the bottom, making sure I had newlines after the defines.

Now, if I ctrl-click on "double", it doesn't take me to the #define found in the Matlab headers (like it used to), but it shows me a huge list of every place where double is a return value of some function or typedef'd in someway (i.e. most of these are in the stable Visual Studio includes like the Platform SDK and c-runtime includes.

Any other ideas?

BTW, I wasn't able to attach a 128kb jpeg screen grab to this post. Kept getting errors saying file was too big, was using invalid characters, etc. Don't think any of those were the case.
diarrhio Posted - Apr 29 2010 : 11:28:27 AM
Got it. Thanks.
accord Posted - Apr 29 2010 : 03:51:08 AM
VA parses both active and inactive code so can help with suggestions regardless of the active configuration. (i.e. debug, release)

To workaround this, you can place

#define double double
#define float float

lines into VA's stdafx.h. This is only parsed by VA and the macros won't get overwitten later. You can find info about how to edit this file here:

http://docs.wholetomato.com?W302

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