News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

Code completion for class in namespace

Started by jleedixon, November 12, 2008, 08:12:09 PM

Previous topic - Next topic

jleedixon

I'm a newbie to code::blocks, and am pretty impressed so far.  Code completion works well, but it seems to not work well with namespaces.  My example is pretty simple.  When I try to do code completion to get the "myVar" attribute, I get no listing at all.  If I just remove the MyClass from the namespace, it works fine.

Is there a setting somewhere that I am missing?  Can anyone else verify this problem, or is it just me?  I have searched the forums but haven't seen anybody ask about this recently.

(Using v 8.02 on Ubuntu 7.10)

----- header file --------
namespace MyNamespace
{
  class MyClass
  {
  public:
    void MyFunc();
    int myVar;
  };

};



--- source file ---

#include "header file"

using namespace MyNamespace;

void MyClass::MyFunc()
{
  myVar = 5;   // code completion does not work here
}


ollydbg

#1
I tested it in the svn version of windows.
It still doesn't work. :(.

But, if you comment the namespace related code, it can work OK.

And there's no place to report this kind of bug to the developers. I search the forum with the keyword "code completion, many related question has left alone with no answers. :(
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.