[svn r124] Fixed another D vararg + return in ptr bug.

Fixed some nested function calls failed to resolve the context ptr.
This commit is contained in:
Tomas Lindquist Olsen
2007-11-26 07:26:21 +01:00
parent 282f60e4a0
commit 935dfae9c8
6 changed files with 53 additions and 6 deletions

9
test/bug76.d Normal file
View File

@@ -0,0 +1,9 @@
module bug76;
char[] fmt(...)
{
return "";
}
void main()
{
char[] s = fmt();
}

17
test/bug77.d Normal file
View File

@@ -0,0 +1,17 @@
module bug77;
import std.c.string;
void main()
{
size_t len;
void func2()
{
char* prefix = "";
void func()
{
len = strlen(prefix);
assert(len == 0);
}
}
func2();
}

15
test/strings2.d Normal file
View File

@@ -0,0 +1,15 @@
module strings2;
import std.string;
import std.stdio;
void main()
{
int i = 32;
auto str = format(i);
writefln(str);
long l = 123123;
str = format(l);
writefln(str);
}