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
 Bug in "Create implementation"
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

stefan_reinalter
New Member

Austria
5 Posts

Posted - Sep 24 2021 :  04:52:40 AM  Show Profile  Reply with Quote
When using "Create implementation" on a function in a header file, VAX will fail to correctly scope return arguments whenever a macro is also used (e.g. for attributes).

The following code reproduces the problem:

Place the following into a header file:

#define LPP_NO_DISCARD [[no_discard]]

namespace Outer
{
  enum class Nested
  {
    Test
  };

  [[no_discard]] Nested Works(void);
  LPP_NO_DISCARD Nested Fails(void);
}


Using "Create implementation" on both Works and Fails yields the following in the .cpp file:


Outer::Nested Outer::Works(void)
{

}

LPP_NO_DISCARD Nested Outer::Fails(void)
{

}


Notice how with Works(), the return type Nested is properly scoped (Outer::Nested), whereas with Fails(), the return type is missing the scope operator Outer::.

feline
Whole Tomato Software

United Kingdom
17436 Posts

Posted - Sep 24 2021 :  1:02:36 PM  Show Profile  Reply with Quote
I am seeing the same effect here. Thank you for the clear description.

case=146244

No simple work around for this one I am afraid.

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:
© 2021 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000