trait sad @a = ree : (a : @a -> void) ;; type foo = union `Foo `Bar ;; impl sad foo = ree = {a } ;; type bar = foo const asbar = {r : foo -> (r : bar) } impl sad bar = ree = {a } ;; impl sad int = ree = {a } ;; const main = { var a = ree(`Foo) // var b = ree((`Foo : foo)) // var c = ree(asbar(`Foo)) // var d = ree(1) } /* Process 37943 stopped * thread #1, queue = 'com.apple.main-thread', stop reason = breakpoint 1.1 frame #0: 0x00000001000343a0 6m`putdcl(st=0x0000000100202cd0, s=0x0000000100303e60) at stab.c:418 415 { 416 Node *old; 417 -> 418 st = findstab(st, s->decl.name); 419 old = htget(st->dcl, s->decl.name); 420 if (!old) 421 forcedcl(st, s); Target 0: (6m) stopped. (lldb) p s->decl.name->name (Node::(anonymous struct)) $5 = (ns = , name = "ree$$n$foo$$fv$$n$foo$") (lldb) c Process 37943 resuming Process 37943 stopped * thread #1, queue = 'com.apple.main-thread', stop reason = breakpoint 2.1 frame #0: 0x000000010003237b 6m`specializedcl(gnode=0x0000000100500c80, param=0x0000000100301b40, to=0x0000000100207160, name=0x00007ffeefbff1f8) at specialize.c:551 548 st = file->file.globls; 549 if (!st) 550 fatal(n, "Can't find symbol table for %s.%s", n->name.ns, n->name.name); -> 551 d = getdcl(st, n); 552 if (d) 553 return d; 554 if (gnode->decl.trait) { Target 0: (6m) stopped. (lldb) p n->name (Node::(anonymous struct)) $6 = (ns = , name = "ree$$u50$$fv$$u50$") */