Rubeus
Member
|
Code editor: local using directive bug
Due the the EE code being all-inclusive, I try to put sections into namespaces in order to keep things clean. I found that when working with the 'using' directive in a local scope, the code editor doesn't know what to do with it. For instance:
Code:
namespace A{
class j
{
foo();
}
}
void bar() {
using namespace A;
j *J = new j(); // Works, but j does not turn blue as expected
J.foo(); // This throws a compiler error
J->foo(); // This compiles, but the editor does not give a pulldown
// list as would be expected
}
It looks like the code editor doesn't turn the code into proper C++ because it doesn't know what's going on with the local "using" directive.
|
|
08-26-2013 04:16 PM |
|
Esenthel
Administrator
|
RE: Code editor: local using directive bug
Hi, "using" keyword is not yet supported and is on the roadmap.
You can use namespaces, but just access classes via full path "namespace.class"
|
|
08-26-2013 09:54 PM |
|
Rubeus
Member
|
RE: Code editor: local using directive bug
Ah, I see. I had one particular section where it got pretty ridiculous with all the namespace prefixes, and adding the "using" cleared a lot of clutter. It still compiles, if one uses proper C++, it just limits the fanciness of the code editor. It's not a big deal for that single function, so I'll keep the readability over the IntelliSense-style(EsenthelSense?) menu.
I'm looking forward to new updates.
|
|
08-26-2013 11:41 PM |
|