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


Christian Kamm <kamm-removet...@incasoftware.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch
                 CC|                            |kamm-removet...@incasoftwar
                   |                            |e.de




--- Comment #4 from Christian Kamm <kamm-removet...@incasoftware.de>  
2009-07-02 07:38:15 PDT ---
Something like this could be added to Statements/If Statement to make the spec
describe DMD's behavior:

If the condition expression v that is passed to the if statement is not of type
bool, a different expression depending on v's type is evaluated instead:
 * integer, floating point, complex, pointer, function: v != 0
 * array: v.ptr != 0
 * associative array: cast(void*)v != 0
 * delegate: v.funcptr != 0
 * class: v !is null
 * struct: error

Note that for struct and class type conditions, it is not equivalent to
evaluating cast(bool)v.

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

Reply via email to