www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 18432] New: alias x = x where x is an imported symbol should

https://issues.dlang.org/show_bug.cgi?id=18432

          Issue ID: 18432
           Summary: alias x = x where x is an imported symbol should
                    result in an error
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: razvan.nitu1305 gmail.com

import std.stdio : writeln;
alias writeln = writeln;

This code should result in an error. On the other hand:

import std.stdio : writeln;
alias writeln = std.stio.writeln;

should compile (and it does momentarily)

--
Feb 13 2018