Bug 9234 – DMD confuses string template parameter with function

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2012-12-28T04:45:00Z
Last change time
2012-12-28T12:52:54Z
Keywords
pull, rejects-valid
Assigned to
nobody
Creator
puneet

Comments

Comment #0 by puneet — 2012-12-28T04:45:29Z
Here is a reduced testcase. Compiles with release 2.060 but fails with the current github snapshot with an error: test.d(8): Error: need 'this' for bar type void() test.d(3): Error: Foo!(bar) is used as a type class Fizz { // 1 void bar() { } // 2 Foo!bar foobar; // 3 } // 4 // 5 struct Foo (alias F) { } // 6 // 7 struct Foo (string THUNK) { } // 8 // 9 void main() { } // 10
Comment #1 by k.hara.pg — 2012-12-28T05:29:55Z
This regression is caused by fixing bug 8251.
Comment #2 by k.hara.pg — 2012-12-28T05:34:39Z
Comment #3 by github-bugzilla — 2012-12-28T11:10:00Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/ad5f125f9074e9b6bd8b362d12556bbbf03042e9 fix Issue 9234 - DMD confuses string template parameter with function https://github.com/D-Programming-Language/dmd/commit/e32197e6150c02671b609c881b602f20dea9d4c6 Merge pull request #1420 from 9rnsr/fix9234 Issue 9234 - DMD confuses string template parameter with function
Comment #4 by github-bugzilla — 2012-12-28T11:11:04Z
Commit pushed to staging at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/dff92ecbadea3c959aeb5f99d42f08324b981aae Merge pull request #1420 from 9rnsr/fix9234 Issue 9234 - DMD confuses string template parameter with function