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
 Namespaces in Implement Virtual Methods
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

markyxl
Starting Member

1 Posts

Posted - Apr 01 2016 :  02:52:06 AM  Show Profile  Reply with Quote
Given following code:

namespace SomeNamespace
{
  struct TypeInNamespace {int _x;};

  class Interface
  {
  public:
    virtual TypeInNamespace Method() = 0;
  };
}

class ImplementationClass : public SomeNamespace::Interface
{

};


If you go to "Implement Virtual Methods..." and implement SomeNamespace::Interface in ImplementationClass, it generates code that doesn't compile because it omits the namespace for the return type:

class ImplementationClass : public SomeNamespace::Interface
{
public:
  virtual TypeInNamespace Method() override
  {
    throw std::logic_error("The method or operation is not implemented.");
  }
};


At first I thought it might be fixed in case=26956, but after re-testing it in build 2094 the issue is still there. Could this please be fixed in future releases? I use the Implement Virtual Methods feature quite a lot, but having to manually add namespaces to every line it generates kind of defeats the purpose.


Build number of Visual Assist: 2094
IDE and version you are using: Visual Studio 2012 update 5, Visual Studio 2015
Programming language(s) in which the problem occurs: C++

Edited by - markyxl on Apr 01 2016 02:58:03 AM

feline
Whole Tomato Software

United Kingdom
19014 Posts

Posted - Apr 01 2016 :  12:20:57 PM  Show Profile  Reply with Quote
I am seeing the same effect here. Thank you for the clear description.

case=69047

Unfortunately I don't currently have an estimate for when this will be looked at, but we are working to improve our support for and handling of namespaces.

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