[Issue 2992] std.typecons has unnecessary thread local globals

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat May 16 10:55:26 PDT 2009


http://d.puremagic.com/issues/show_bug.cgi?id=2992





--- Comment #1 from Jason House <jason.james.house at gmail.com>  2009-05-16 10:55:25 PDT ---
On second thought, this may be an undocumented "feature" that allows changing
how output formatting is handled.  If that's true, the nature of this bug
report is really much different.  Use of globals for that purpose leaves
residual side effects that can affect other calls to the function that
expect/require normal handling.  There are two basic options:
1. There should be a formatter struct that stores the customized state (the
default free functions could simply call the formatting functions of the struct
on an invariant global formatting struct.
2. Put these formatting arguments as default parameters on calls that use them

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list