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

          Issue ID: 22327
           Summary: [Templates] arguments of T[] literals work for exactly
                    one initialization before being set in stone
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd
          Assignee: nob...@puremagic.com
          Reporter: crazymonk...@gmail.com

Created attachment 1827
  --> https://issues.dlang.org/attachment.cgi?id=1827&action=edit
minimized

given a template header such as `struct foo(T,T[] data)`, T[] data appears to
mean whatever the first init defined T as

This is across scope, functions and unit tests, if the first initization is
int,[1,2,3], and you try string.["a","b","c"], it attempts to parse
["a","b","c"] as an int[]

--

Reply via email to