nanopass / nanopass-framework-racket

nanopass compiler framework for Racket
http://nanopass.org
MIT License
181 stars 29 forks source link

broken internal invariants? expected record, given #f #25

Closed jbclements closed 5 years ago

jbclements commented 5 years ago

I haven't tried to minimize this example, I just don't have time, but this looks like a bug in nanopass. Specifically, running the file nanopass-c.rkt produces this error message:

nanopass-record-tag: contract violation expected: nanopass-record? given: #f

I don't think nanopass-record-tags should be visible to me, really.

This is totally not on the critical path for me, because there are big unimplemented chunks, so I think I know how to fix this; it's just that this error message doesn't make any sense to me.

(ooh, I have to rename them as text files to paste them, sigh.)

nanopass-c.txt nanopass-compiler.txt

jbclements commented 5 years ago

urrgh, just ran into this again, sigh.

jbclements commented 5 years ago

Ah, okay... I'm starting to understand this is actually a pretty reasonable error message: it occurs when I pass something that should be a nanopass record, but isn't. I think the 'nanopass-record-tag' was a red herring... sort of. I'm going to close this.