Summary: Bug? Pointer advancing is possible.
           Product: D
           Version: future
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from Haruki Shigemori <> 2010-04-28 09:21:00 
PDT ---
void main() @safe
    int a;
    int* p = &a;

This code is able to compile.

* References []

- Safe Functions

Safe functions are marked with the @safe attribute.

The following operations are not allowed in safe functions:

- No casting from a pointer type to any type other than void*.
- No casting from any non-pointer type to a pointer type.
- No modification of pointer values. <-------------------------------- here!

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to