875 – crash in glue.c line 700

D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 875 - crash in glue.c line 700
Summary: crash in glue.c line 700
Status: RESOLVED FIXED
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D1 (retired)
Hardware: x86 Linux
: P2 normal
Assignee: Walter Bright
URL:
Keywords:
Depends on:
Blocks:
Reported: 2007年01月22日 22:21 UTC by Kevin Bealer
Modified: 2014年02月15日 13:13 UTC (History)
0 users

See Also:


Attachments
Add an attachment (proposed patch, testcase, etc.)

Note You need to log in before you can comment on or make changes to this issue.
Description Kevin Bealer 2007年01月22日 22:21:21 UTC
Boiled down code shown below; I'm not sure how legal this syntax should be, but its enough to derail dmd. What I'm trying to do is specialize on two variadic type lists by wrapping them in tuples.
Thanks,
Kevin
-----
import std.traits;
int main(char[][] args)
{
 double bongos(int flux, char[] soup)
 {
 return 0.0;
 }
 
 auto foo = mk_future(& bongos, 99, "soup"[]);
 
 return 0;
}
int mk_future(A, B...)(A cmd, B args)
{
 typedef ReturnType!(A) TReturn;
 typedef ParameterTypeTuple!(A) TParams;
 typedef B TArgs;
 
 alias Foo!(TReturn, TParams, TArgs) TFoo;
 
 return 0;
}
class Foo(A, B, C) {
 this(A delegate(B), C)
 {
 }
}
-----
dmd -ofbasic basic.d
dmd: glue.c:700: virtual unsigned int Type::totym(): Assertion `0' failed.
Comment 1 Walter Bright 2007年02月12日 03:40:27 UTC
Fixed DMD 1.005


AltStyle によって変換されたページ (->オリジナル) /