http://d.puremagic.com/issues/show_bug.cgi?id=8287
Summary: When a class with the same name as a module exists within that module and has static members, you're required to do modulename.classname.member() in order to access said members Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: tbrisb...@hotmail.com --- Comment #0 from Trey Brisbane <tbrisb...@hotmail.com> 2012-06-23 03:24:09 PDT --- Pretty much exactly what the summary says. Here is an example: File 1: module objectA; class objectA { public static void doSomething() { ... } } File 2: module main; import objectA; int main(string[] args) { objectA.doSomething(); // Error: undefined identifier 'doSomething' objectA.objectA.doSomething(); // Ok return 0; } Obviously, the compiler is searching for a function called doSomething in the module objectA, when it should instead recognize that a class called objectA has been imported and an attempt is being made to access its static member doSomething(). Please note that this is my first bug submission, so if it's already known (I did search before posting this) or has a simple fix, please forgive me. :) -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------