digitalmars.D - Template alias parameter does not accept primitives?
- KennyTM~ (9/9) Mar 05 2011 template Foo(alias A) {
template Foo(alias A) {
alias A Foo;
}
Foo!(int) x;
This piece of code will not compile in both D1 and D2 because 'int'
cannot be matched with 'alias A'. Is this expected? Why is that?
Refs:
1. http://codepad.org/GQFBdC0T
2. http://ideone.com/yke0h
Mar 05 2011








KennyTM~ <kennytm gmail.com>