Thread overview | ||||||
---|---|---|---|---|---|---|
|
January 03, 2011 [Issue 5404] New: .stringof is not documented | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=5404 Summary: .stringof is not documented Product: D Version: D2 Platform: Other OS/Version: All Status: NEW Severity: normal Priority: P2 Component: websites AssignedTo: nobody@puremagic.com ReportedBy: peter.alexander.au@gmail.com --- Comment #0 from Peter Alexander <peter.alexander.au@gmail.com> 2011-01-03 12:48:09 PST --- The usage of .stringof on its own (with no preceding object) doesn't appear to be documented anywhere, yet it appears to be legal and returns the name of the module it resides in, e.g. in foo.d, it would evaluate to "module foo". This should be added to the language spec. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
January 03, 2011 [Issue 5404] .stringof is not documented | ||||
---|---|---|---|---|
| ||||
Posted in reply to Peter Alexander | http://d.puremagic.com/issues/show_bug.cgi?id=5404 --- Comment #1 from Peter Alexander <peter.alexander.au@gmail.com> 2011-01-03 12:50:18 PST --- Also, if we are in module foo.bar, it returns "module bar". Is this correct behaviour? -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
January 03, 2011 [Issue 5404] .stringof is not documented | ||||
---|---|---|---|---|
| ||||
Posted in reply to Peter Alexander | http://d.puremagic.com/issues/show_bug.cgi?id=5404 --- Comment #2 from Peter Alexander <peter.alexander.au@gmail.com> 2011-01-03 13:02:17 PST --- Finally, is there any reason that the return value is prefixed with "module"? 1. I can't imagine any use for it. 2. If people needed it, it would be trivial to add ("module " ~ .stringof) 3. If they don't want it, it's a little trickier (splitter(.stringof)[1], or ugly .stringof[7..$]) I would recommend that in module foo, .stringof == "foo". -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
January 12, 2013 [Issue 5404] .stringof is not documented | ||||
---|---|---|---|---|
| ||||
Posted in reply to Peter Alexander | http://d.puremagic.com/issues/show_bug.cgi?id=5404 Andrej Mitrovic <andrej.mitrovich@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |andrej.mitrovich@gmail.com Resolution| |DUPLICATE --- Comment #3 from Andrej Mitrovic <andrej.mitrovich@gmail.com> 2013-01-11 19:54:13 PST --- *** This issue has been marked as a duplicate of issue 3007 *** -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation