More D newb questions.
Me Here
p9e883002 at sneakemail.com
Fri May 9 04:46:05 PDT 2008
BCS wrote:
> void Fn(T)()
> {
> T a, b;
> auto c = a ~ b;
> T d = c;
> }
Okay. What do you think happens when you try to compile this?
import std.stdio;
T Fn(T)( T a, T b ) {
auto c = a ~ b;
T d = c;
return d;
}
int main( char[][] args ) {
char[][] a = [ [ 'a', 'b' ], [ 'c', 'd' ] ];
char[][] b = [ [ 'p', 'q' ], [ 'r', 's' ] ];
writefln( Fn!( char[][] )( a, b ) );
return 1;
}
--
More information about the Digitalmars-d
mailing list