soegaard / whalesong

Whalesong: Racket to JavaScript compiler
http://hashcollision.org/whalesong
145 stars 14 forks source link

The #:reflection-name struct option causes a runtime error #46

Open lexi-lambda opened 9 years ago

lexi-lambda commented 9 years ago

Trying to declare a struct with the #:reflection-name option causes an error in the runtime:

(struct foo () #:reflection-name 'bar)
TypeError: Cannot read property 'prefix' of undefined
    at _400 [as p] (file:///tmp/dist/struct_1.js:104:262)
    at _448 (file:///tmp/dist/struct_1.js:215:12)
    at Machine._trampoline (file:///tmp/dist/struct.js:13640:17)
    at null.<anonymous> (file:///tmp/dist/struct.js:13691:38)
    at ExclusiveLock.acquire (file:///tmp/dist/struct.js:13216:23)
    at restart (file:///tmp/dist/struct.js:13686:35)
    at file:///tmp/dist/struct_1.js:231:50
    at Object.currentModuleLoader (file:///tmp/dist/struct.js:14296:24)
    at null.onPause (file:///tmp/dist/struct_1.js:228:26)
    at Machine._trampoline (file:///tmp/dist/struct.js:13719:23)