www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 16025] New: mixin myTemplate should throw an error

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

          Issue ID: 16025
           Summary: mixin myTemplate should throw an error
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: greensunny12 gmail.com

problem:

mixin myTemplate; // silently doesn't work
mixin(myTemplate);

solution:
1) Throw an error for the silent case
2) allow mixin statements without parenthesis (preferred solution)

--
May 14 2016