diff options
Diffstat (limited to 'test/TableGen/lisp.td')
-rw-r--r-- | test/TableGen/lisp.td | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/TableGen/lisp.td b/test/TableGen/lisp.td new file mode 100644 index 0000000000..3e392fda84 --- /dev/null +++ b/test/TableGen/lisp.td @@ -0,0 +1,21 @@ +// RUN: tblgen %s | grep {} + +class List<list<string> n> { + list<string> names = n; +} + +class CAR<string e> { + string element = e; +} + +class CDR<list<string> r, int n> { + list<string> rest = r; + int null = n; +} + +class NameList<list<string> Names> : + List<Names>, CAR<!car(Names)>, CDR<!cdr(Names), !null(!cdr(Names))>; + +def Three : NameList<["Tom", "Dick", "Harry"]>; + +def One : NameList<["Jeffrey Sinclair"]>; |