Mercurial > projects > ldc
view test/bug10.d @ 289:17d3b3236334 trunk
[svn r310] Fixed a problem with incomplete types and templates in typeinfo code.
author | lindquist |
---|---|
date | Sat, 21 Jun 2008 16:22:29 +0200 |
parents | d9d5d59873d8 |
children |
line wrap: on
line source
module bug10; extern(C) int printf(char*, ...); class C { char[] msg; this() { } this(char[] msg) { this.msg = msg; } } void main() { auto c = new C(); c.msg = "world"; auto b = new C("hello"); printf("%.*s\n", b.msg.length, b.msg.ptr); printf("%.*s\n", c.msg.length, c.msg.ptr); }