Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Technical Support
 VAX doesn't understand __restrict in C++
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

.oisyn
Tomato Guru

162 Posts

Posted - Nov 02 2008 :  6:19:36 PM  Show Profile  Reply with Quote
When using VC++'s __restrict extension, VA X shows __restrict with a red error underline.

void Foo(void * __restrict a, void * __restrict b)
{
}


Note that __restrict is part of the ISO C99 standard, but that microsoft supports it in C++ as well. It would be nice if VA X did that too.

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Nov 04 2008 :  2:46:53 PM  Show Profile  Reply with Quote
I am seeing the same effect here. Thank you for the clear description.

case=20732
Go to Top of Page

support
Whole Tomato Software

5566 Posts

Posted - Dec 01 2008 :  07:45:58 AM  Show Profile  Reply with Quote
case=20732 is fixed in build 1707
Go to Top of Page

zeroes00
Junior Member

17 Posts

Posted - Dec 17 2010 :  4:01:39 PM  Show Profile  Reply with Quote
The new Intel c++ compiler supports restrict keyword (without the underscore prefixes) but VA X doesn't recognize that. To my understanding it's the same thing as the underscored VC++ extension and I'd like to use it because it's shorter to write.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
18751 Posts

Posted - Dec 20 2010 :  2:58:50 PM  Show Profile  Reply with Quote
Can you try the following please. Edit VA's "StdAfx.h" file as explained in this FAQ entry:

http://docs.wholetomato.com?W302

and add the entry:

#define restrict __restrict

at the bottom. This file is used to help VA's parser with difficult code, and can be used to work around odd effects. After modifying this file you need to rebuild the VA symbol database for the changes to take effect:

VA Options -> Performance -> General -> Rebuild symbol databases

I have just tried this here, and based on a few simple tests it seems to be working well.

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000