blob: 5a1fc7ee405ce874a1b9f663ab4c88cea2888bbd [file] [log] [blame]
David Greenede444af2009-04-22 16:42:54 +00001// RUN: tblgen %s | grep {zing = 4} | count 4
2
3class C1<int A, string B> {
4 int bar = A;
5 string thestr = B;
6 int zing;
7}
8
9def T : C1<4, "blah">;
10
11multiclass t<int a> {
12 def S1 : C1<a, "foo"> {
13 int foo = 4;
14 let bar = 1;
15 }
16 def S2 : C1<a, "bar">;
17}
18
19multiclass s<int a, int b> : t<a> {
20 def S3 : C1<b, "moo"> {
21 int moo = 3;
22 let bar = 1;
23 }
24 def S4 : C1<b, "baz">;
25}
26
27defm FOO : s<42, 24>;
28
29def T4 : C1<6, "foo">;
30
31let zing = 4 in
32 defm BAZ : s<3, 4>;