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

           Summary: cast() operation not fully specified
           Product: D
           Version: D2
          Platform: Other
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: websites
        AssignedTo: nob...@puremagic.com
        ReportedBy: cokebut...@gmail.com


--- Comment #0 from Lennart Blanco <cokebut...@gmail.com> 2011-08-30 22:41:57 
PDT ---
The D2 language specification does not fully define the conversation performed
by cast() operation,
http://d-programming-language.org/expression.html#CastExpression.

For example cast() between basic data types of different sizes and signess is
not described.

e.g:

  int a;
  byte b = cast(int)a;

Casting pointers to basic data types is also not described.

I think the specification should define when the value is truncated, sign
extended or copied bit-by-bit, etc.

Maybe a reference to relevant C language specification would solve this issue.

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

Reply via email to