picrin/lib/ext/boot.c

590 lines
47 KiB
C
Raw Normal View History

2016-03-03 04:59:07 -05:00
#include "picrin.h"
#include "picrin/extra.h"
static const char boot_rom[][80] = {
2017-04-04 01:54:58 -04:00
"((core#lambda (.define-transformer.2149 .the.2150) ((core#lambda (.the-core-defi",
"ne.2151 .the-core-lambda.2152 .the-core-begin.2153 .the-core-quote.2154 .the-cor",
"e-set!.2155 .the-core-if.2156 .the-core-define-macro.2157 .the-define.2158 .the-",
"lambda.2159 .the-begin.2160 .the-quote.2161 .the-set!.2162 .the-if.2163 .the-def",
"ine-macro.2164) (core#begin (.define-transformer.2149 (core#quote quote) (core#l",
"ambda (.form.2169 .env.2170) (core#if (= (length .form.2169) 2) (cons .the-core-",
"quote.2154 (cons (cadr .form.2169) (core#quote ()))) (error \"malformed quote\" .f",
"orm.2169)))) (core#begin (.define-transformer.2149 (core#quote if) (core#lambda ",
"(.form.2171 .env.2172) ((core#lambda (.len.2173) (core#if (= .len.2173 3) (appen",
"d .form.2171 (cons (core#quote #undefined) (core#quote ()))) (core#if (= .len.21",
"73 4) (cons .the-core-if.2156 (cdr .form.2171)) (error \"malformed if\" .form.2171",
")))) (length .form.2171)))) (core#begin (.define-transformer.2149 (core#quote be",
"gin) (core#lambda (.form.2174 .env.2175) ((core#lambda (.len.2176) (core#if (= .",
"len.2176 1) #undefined (core#if (= .len.2176 2) (cadr .form.2174) (core#if (= .l",
"en.2176 3) (cons .the-core-begin.2153 (cdr .form.2174)) (cons .the-core-begin.21",
"53 (cons (cadr .form.2174) (cons (cons .the-begin.2160 (cddr .form.2174)) (core#",
"quote ())))))))) (length .form.2174)))) (core#begin (.define-transformer.2149 (c",
"ore#quote set!) (core#lambda (.form.2177 .env.2178) (core#if (core#if (= (length",
" .form.2177) 3) (identifier? (cadr .form.2177)) #f) (cons .the-core-set!.2155 (c",
"dr .form.2177)) (error \"malformed set!\" .form.2177)))) (core#begin (core#define ",
".check-formal.2165 (core#lambda (.formal.2179) ((core#lambda (.it.2180) (core#if",
" .it.2180 .it.2180 ((core#lambda (.it.2181) (core#if .it.2181 .it.2181 ((core#la",
"mbda (.it.2182) (core#if .it.2182 .it.2182 #f)) (core#if (pair? .formal.2179) (c",
"ore#if (identifier? (car .formal.2179)) (.check-formal.2165 (cdr .formal.2179)) ",
"#f) #f)))) (identifier? .formal.2179)))) (null? .formal.2179)))) (core#begin (.d",
"efine-transformer.2149 (core#quote lambda) (core#lambda (.form.2183 .env.2184) (",
"core#if (= (length .form.2183) 1) (error \"malformed lambda\" .form.2183) (core#if",
" (.check-formal.2165 (cadr .form.2183)) (cons .the-core-lambda.2152 (cons (cadr ",
".form.2183) (cons (cons .the-begin.2160 (cddr .form.2183)) (core#quote ())))) (e",
"rror \"malformed lambda\" .form.2183))))) (core#begin (.define-transformer.2149 (c",
"ore#quote define) (core#lambda (.form.2185 .env.2186) ((core#lambda (.len.2187) ",
"(core#if (= .len.2187 1) (error \"malformed define\" .form.2185) ((core#lambda (.f",
"ormal.2188) (core#if (identifier? .formal.2188) (core#if (= .len.2187 3) (cons .",
"the-core-define.2151 (cdr .form.2185)) (error \"malformed define\" .form.2185)) (c",
"ore#if (pair? .formal.2188) (cons .the-define.2158 (cons (car .formal.2188) (con",
"s (cons .the-lambda.2159 (cons (cdr .formal.2188) (cddr .form.2185))) (core#quot",
"e ())))) (error \"define: binding to non-varaible object\" .form.2185)))) (cadr .f",
"orm.2185)))) (length .form.2185)))) (core#begin (.define-transformer.2149 (core#",
"quote define-macro) (core#lambda (.form.2189 .env.2190) (core#if (= (length .for",
"m.2189) 3) (core#if (identifier? (cadr .form.2189)) (cons .the-core-define-macro",
".2157 (cdr .form.2189)) (error \"define-macro: binding to non-variable object\" .f",
"orm.2189)) (error \"malformed define-macro\" .form.2189)))) (core#begin #undefined",
" (core#begin (.define-transformer.2149 (core#quote else) (core#lambda ._.2191 (e",
2017-04-03 14:55:23 -04:00
"rror \"invalid use of auxiliary syntax\" (core#quote else)))) (core#begin (.define",
2017-04-04 01:54:58 -04:00
"-transformer.2149 (core#quote =>) (core#lambda ._.2192 (error \"invalid use of au",
"xiliary syntax\" (core#quote =>)))) (core#begin (.define-transformer.2149 (core#q",
"uote unquote) (core#lambda ._.2193 (error \"invalid use of auxiliary syntax\" (cor",
"e#quote unquote)))) (core#begin (.define-transformer.2149 (core#quote unquote-sp",
"licing) (core#lambda ._.2194 (error \"invalid use of auxiliary syntax\" (core#quot",
"e unquote-splicing)))) (core#begin (.define-transformer.2149 (core#quote let) (c",
"ore#lambda (.form.2195 .env.2196) (core#if (identifier? (cadr .form.2195)) ((cor",
"e#lambda (.name.2197 .formal.2198 .body.2199) (cons (cons .the-lambda.2159 (cons",
" (core#quote ()) (cons (cons .the-define.2158 (cons (cons .name.2197 (map car .f",
"ormal.2198)) .body.2199)) (cons (cons .name.2197 (map cadr .formal.2198)) (core#",
"quote ()))))) (core#quote ()))) (car (cdr .form.2195)) (car (cdr (cdr .form.2195",
"))) (cdr (cdr (cdr .form.2195)))) ((core#lambda (.formal.2200 .body.2201) (cons ",
"(cons .the-lambda.2159 (cons (map car .formal.2200) .body.2201)) (map cadr .form",
"al.2200))) (car (cdr .form.2195)) (cdr (cdr .form.2195)))))) (core#begin (.defin",
"e-transformer.2149 (core#quote and) (core#lambda (.form.2202 .env.2203) (core#if",
" (null? (cdr .form.2202)) #t (core#if (null? (cddr .form.2202)) (cadr .form.2202",
") (cons .the-if.2163 (cons (cadr .form.2202) (cons (cons (.the.2150 (core#quote ",
"and)) (cddr .form.2202)) (cons (core#quote #f) (core#quote ()))))))))) (core#beg",
"in (.define-transformer.2149 (core#quote or) (core#lambda (.form.2204 .env.2205)",
" (core#if (null? (cdr .form.2204)) #f ((core#lambda (.tmp.2206) (cons (.the.2150",
" (core#quote let)) (cons (cons (cons .tmp.2206 (cons (cadr .form.2204) (core#quo",
"te ()))) (core#quote ())) (cons (cons .the-if.2163 (cons .tmp.2206 (cons .tmp.22",
"06 (cons (cons (.the.2150 (core#quote or)) (cddr .form.2204)) (core#quote ()))))",
") (core#quote ()))))) (make-identifier (core#quote it) .env.2205))))) (core#begi",
"n (.define-transformer.2149 (core#quote cond) (core#lambda (.form.2207 .env.2208",
") ((core#lambda (.clauses.2209) (core#if (null? .clauses.2209) #undefined ((core",
"#lambda (.clause.2210) (core#if (core#if (identifier? (car .clause.2210)) (ident",
"ifier=? (.the.2150 (core#quote else)) (make-identifier (car .clause.2210) .env.2",
"208)) #f) (cons .the-begin.2160 (cdr .clause.2210)) (core#if (null? (cdr .clause",
".2210)) (cons (.the.2150 (core#quote or)) (cons (car .clause.2210) (cons (cons (",
".the.2150 (core#quote cond)) (cdr .clauses.2209)) (core#quote ())))) (core#if (c",
"ore#if (identifier? (cadr .clause.2210)) (identifier=? (.the.2150 (core#quote =>",
")) (make-identifier (cadr .clause.2210) .env.2208)) #f) ((core#lambda (.tmp.2211",
") (cons (.the.2150 (core#quote let)) (cons (cons (cons .tmp.2211 (cons (car .cla",
"use.2210) (core#quote ()))) (core#quote ())) (cons (cons .the-if.2163 (cons .tmp",
".2211 (cons (cons (cadr (cdr .clause.2210)) (cons .tmp.2211 (core#quote ()))) (c",
"ons (cons (.the.2150 (core#quote cond)) (cddr .form.2207)) (core#quote ()))))) (",
"core#quote ()))))) (make-identifier (core#quote tmp) .env.2208)) (cons .the-if.2",
"163 (cons (car .clause.2210) (cons (cons .the-begin.2160 (cdr .clause.2210)) (co",
"ns (cons (.the.2150 (core#quote cond)) (cdr .clauses.2209)) (core#quote ()))))))",
"))) (car .clauses.2209)))) (cdr .form.2207)))) (core#begin (.define-transformer.",
"2149 (core#quote quasiquote) (core#lambda (.form.2212 .env.2213) (core#begin (co",
"re#define .quasiquote?.2214 (core#lambda (.form.2218) (core#if (pair? .form.2218",
") (core#if (identifier? (car .form.2218)) (identifier=? (.the.2150 (core#quote q",
"uasiquote)) (make-identifier (car .form.2218) .env.2213)) #f) #f))) (core#begin ",
"(core#define .unquote?.2215 (core#lambda (.form.2219) (core#if (pair? .form.2219",
") (core#if (identifier? (car .form.2219)) (identifier=? (.the.2150 (core#quote u",
"nquote)) (make-identifier (car .form.2219) .env.2213)) #f) #f))) (core#begin (co",
"re#define .unquote-splicing?.2216 (core#lambda (.form.2220) (core#if (pair? .for",
"m.2220) (core#if (pair? (car .form.2220)) (core#if (identifier? (caar .form.2220",
")) (identifier=? (.the.2150 (core#quote unquote-splicing)) (make-identifier (caa",
"r .form.2220) .env.2213)) #f) #f) #f))) (core#begin (core#define .qq.2217 (core#",
"lambda (.depth.2221 .expr.2222) (core#if (.unquote?.2215 .expr.2222) (core#if (=",
" .depth.2221 1) (cadr .expr.2222) (list (.the.2150 (core#quote list)) (list (.th",
"e.2150 (core#quote quote)) (.the.2150 (core#quote unquote))) (.qq.2217 (- .depth",
".2221 1) (car (cdr .expr.2222))))) (core#if (.unquote-splicing?.2216 .expr.2222)",
" (core#if (= .depth.2221 1) (list (.the.2150 (core#quote append)) (car (cdr (car",
" .expr.2222))) (.qq.2217 .depth.2221 (cdr .expr.2222))) (list (.the.2150 (core#q",
"uote cons)) (list (.the.2150 (core#quote list)) (list (.the.2150 (core#quote quo",
"te)) (.the.2150 (core#quote unquote-splicing))) (.qq.2217 (- .depth.2221 1) (car",
" (cdr (car .expr.2222))))) (.qq.2217 .depth.2221 (cdr .expr.2222)))) (core#if (.",
"quasiquote?.2214 .expr.2222) (list (.the.2150 (core#quote list)) (list (.the.215",
"0 (core#quote quote)) (.the.2150 (core#quote quasiquote))) (.qq.2217 (+ .depth.2",
"221 1) (car (cdr .expr.2222)))) (core#if (pair? .expr.2222) (list (.the.2150 (co",
"re#quote cons)) (.qq.2217 .depth.2221 (car .expr.2222)) (.qq.2217 .depth.2221 (c",
"dr .expr.2222))) (core#if (vector? .expr.2222) (list (.the.2150 (core#quote list",
"->vector)) (.qq.2217 .depth.2221 (vector->list .expr.2222))) (list (.the.2150 (c",
"ore#quote quote)) .expr.2222)))))))) ((core#lambda (.x.2223) (.qq.2217 1 .x.2223",
")) (cadr .form.2212)))))))) (core#begin (.define-transformer.2149 (core#quote le",
"t*) (core#lambda (.form.2224 .env.2225) ((core#lambda (.bindings.2226 .body.2227",
") (core#if (null? .bindings.2226) (cons (.the.2150 (core#quote let)) (cons (core",
"#quote ()) .body.2227)) (cons (.the.2150 (core#quote let)) (cons (cons (cons (ca",
"r (car .bindings.2226)) (cdr (car .bindings.2226))) (core#quote ())) (cons (cons",
" (.the.2150 (core#quote let*)) (cons (cdr .bindings.2226) .body.2227)) (core#quo",
"te ())))))) (car (cdr .form.2224)) (cdr (cdr .form.2224))))) (core#begin (.defin",
"e-transformer.2149 (core#quote letrec) (core#lambda (.form.2228 .env.2229) (cons",
" (.the.2150 (core#quote letrec*)) (cdr .form.2228)))) (core#begin (.define-trans",
"former.2149 (core#quote letrec*) (core#lambda (.form.2230 .env.2231) ((core#lamb",
"da (.bindings.2232 .body.2233) ((core#lambda (.variables.2234 .initials.2235) (c",
"ons (.the.2150 (core#quote let)) (cons .variables.2234 (append .initials.2235 (a",
"ppend .body.2233 (core#quote ())))))) (map (core#lambda (.v.2236) (cons .v.2236 ",
"(cons (core#quote #undefined) (core#quote ())))) (map car .bindings.2232)) (map ",
"(core#lambda (.v.2237) (cons (.the.2150 (core#quote set!)) (append .v.2237 (core",
"#quote ())))) .bindings.2232))) (car (cdr .form.2230)) (cdr (cdr .form.2230)))))",
" (core#begin (.define-transformer.2149 (core#quote let-values) (core#lambda (.fo",
"rm.2238 .env.2239) (cons (.the.2150 (core#quote let*-values)) (append (cdr .form",
".2238) (core#quote ()))))) (core#begin (.define-transformer.2149 (core#quote let",
"*-values) (core#lambda (.form.2240 .env.2241) ((core#lambda (.formals.2242 .body",
".2243) (core#if (null? .formals.2242) (cons (.the.2150 (core#quote let)) (cons (",
"core#quote ()) (append .body.2243 (core#quote ())))) ((core#lambda (.formal.2244",
") (cons (.the.2150 (core#quote call-with-values)) (cons (cons .the-lambda.2159 (",
"cons (core#quote ()) (cdr .formal.2244))) (cons (cons (.the.2150 (core#quote lam",
"bda)) (cons (car .formal.2244) (cons (cons (.the.2150 (core#quote let*-values)) ",
"(cons (cdr .formals.2242) .body.2243)) (core#quote ())))) (core#quote ()))))) (c",
"ar .formals.2242)))) (cadr .form.2240) (cddr .form.2240)))) (core#begin (.define",
"-transformer.2149 (core#quote define-values) (core#lambda (.form.2245 .env.2246)",
" ((core#lambda (.formal.2247 .body.2248) ((core#lambda (.tmps.2249) (cons .the-b",
"egin.2160 (append ((core#lambda () (core#begin (core#define .loop.2250 (core#lam",
"bda (.formal.2251) (core#if (identifier? .formal.2251) (cons (cons .the-define.2",
"158 (cons .formal.2251 (cons (core#quote #undefined) (core#quote ())))) (core#qu",
"ote ())) (core#if (pair? .formal.2251) (cons (cons .the-define.2158 (cons (car .",
"formal.2251) (cons (core#quote #undefined) (core#quote ())))) (.loop.2250 (cdr .",
"formal.2251))) (core#quote ()))))) (.loop.2250 .formal.2247)))) (cons (cons (.th",
"e.2150 (core#quote call-with-values)) (cons (cons .the-lambda.2159 (cons (core#q",
"uote ()) .body.2248)) (cons (cons .the-lambda.2159 (cons .tmps.2249 ((core#lambd",
"a () (core#begin (core#define .loop.2252 (core#lambda (.formal.2253 .tmps.2254) ",
"(core#if (identifier? .formal.2253) (cons (cons .the-set!.2162 (cons .formal.225",
"3 (cons .tmps.2254 (core#quote ())))) (core#quote ())) (core#if (pair? .formal.2",
"253) (cons (cons .the-set!.2162 (cons (car .formal.2253) (cons (car .tmps.2254) ",
"(core#quote ())))) (.loop.2252 (cdr .formal.2253) (cdr .tmps.2254))) (core#quote",
" ()))))) (.loop.2252 .formal.2247 .tmps.2249)))))) (core#quote ())))) (core#quot",
"e ()))))) ((core#lambda () (core#begin (core#define .loop.2255 (core#lambda (.fo",
"rmal.2256) (core#if (identifier? .formal.2256) (make-identifier .formal.2256 .en",
"v.2246) (core#if (pair? .formal.2256) (cons (make-identifier (car .formal.2256) ",
".env.2246) (.loop.2255 (cdr .formal.2256))) (core#quote ()))))) (.loop.2255 .for",
"mal.2247)))))) (cadr .form.2245) (cddr .form.2245)))) (core#begin (.define-trans",
"former.2149 (core#quote do) (core#lambda (.form.2257 .env.2258) ((core#lambda (.",
"bindings.2259 .test.2260 .cleanup.2261 .body.2262) ((core#lambda (.loop.2263) (c",
"ons (.the.2150 (core#quote let)) (cons .loop.2263 (cons (map (core#lambda (.x.22",
"64) (cons (car .x.2264) (cons (cadr .x.2264) (core#quote ())))) .bindings.2259) ",
"(cons (cons .the-if.2163 (cons .test.2260 (cons (cons .the-begin.2160 .cleanup.2",
"261) (cons (cons .the-begin.2160 (append .body.2262 (cons (cons .loop.2263 (map ",
"(core#lambda (.x.2265) (core#if (null? (cdr (cdr .x.2265))) (car .x.2265) (car (",
"cdr (cdr .x.2265))))) .bindings.2259)) (core#quote ())))) (core#quote ()))))) (c",
"ore#quote ())))))) (make-identifier (core#quote loop) .env.2258))) (car (cdr .fo",
"rm.2257)) (car (car (cdr (cdr .form.2257)))) (cdr (car (cdr (cdr .form.2257)))) ",
"(cdr (cdr (cdr .form.2257)))))) (core#begin (.define-transformer.2149 (core#quot",
"e when) (core#lambda (.form.2266 .env.2267) ((core#lambda (.test.2268 .body.2269",
") (cons .the-if.2163 (cons .test.2268 (cons (cons .the-begin.2160 (append .body.",
"2269 (core#quote ()))) (cons (core#quote #undefined) (core#quote ())))))) (car (",
"cdr .form.2266)) (cdr (cdr .form.2266))))) (core#begin (.define-transformer.2149",
" (core#quote unless) (core#lambda (.form.2270 .env.2271) ((core#lambda (.test.22",
"72 .body.2273) (cons .the-if.2163 (cons .test.2272 (cons (core#quote #undefined)",
" (cons (cons .the-begin.2160 (append .body.2273 (core#quote ()))) (core#quote ()",
")))))) (car (cdr .form.2270)) (cdr (cdr .form.2270))))) (core#begin (.define-tra",
"nsformer.2149 (core#quote case) (core#lambda (.form.2274 .env.2275) ((core#lambd",
"a (.key.2276 .clauses.2277) ((core#lambda (.the-key.2278) (cons (.the.2150 (core",
"#quote let)) (cons (cons (cons .the-key.2278 (cons .key.2276 (core#quote ()))) (",
"core#quote ())) (cons ((core#lambda () (core#begin (core#define .loop.2279 (core",
"#lambda (.clauses.2280) (core#if (null? .clauses.2280) #undefined ((core#lambda ",
"(.clause.2281) (cons .the-if.2163 (cons (core#if (core#if (identifier? (car .cla",
"use.2281)) (identifier=? (.the.2150 (core#quote else)) (make-identifier (car .cl",
"ause.2281) .env.2275)) #f) #t (cons (.the.2150 (core#quote or)) (append (map (co",
"re#lambda (.x.2282) (cons (.the.2150 (core#quote eqv?)) (cons .the-key.2278 (con",
"s (cons .the-quote.2161 (cons .x.2282 (core#quote ()))) (core#quote ()))))) (car",
" .clause.2281)) (core#quote ())))) (cons (core#if (core#if (identifier? (cadr .c",
"lause.2281)) (identifier=? (.the.2150 (core#quote =>)) (make-identifier (cadr .c",
"lause.2281) .env.2275)) #f) (cons (car (cdr (cdr .clause.2281))) (cons .the-key.",
"2278 (core#quote ()))) (cons .the-begin.2160 (append (cdr .clause.2281) (core#qu",
"ote ())))) (cons (.loop.2279 (cdr .clauses.2280)) (core#quote ())))))) (car .cla",
"uses.2280))))) (.loop.2279 .clauses.2277)))) (core#quote ()))))) (make-identifie",
"r (core#quote key) .env.2275))) (car (cdr .form.2274)) (cdr (cdr .form.2274)))))",
" (core#begin (.define-transformer.2149 (core#quote parameterize) (core#lambda (.",
"form.2283 .env.2284) ((core#lambda (.formal.2285 .body.2286) (cons (.the.2150 (c",
"ore#quote with-dynamic-environment)) (cons (cons (.the.2150 (core#quote list)) (",
"append (map (core#lambda (.x.2287) (cons (.the.2150 (core#quote cons)) (cons (ca",
"r .x.2287) (cons (cadr .x.2287) (core#quote ()))))) .formal.2285) (core#quote ()",
"))) (cons (cons .the-lambda.2159 (cons (core#quote ()) (append .body.2286 (core#",
"quote ())))) (core#quote ()))))) (car (cdr .form.2283)) (cdr (cdr .form.2283))))",
") (.define-transformer.2149 (core#quote define-record-type) (core#lambda (.form.",
"2288 .env.2289) ((core#lambda (.type.2290 .ctor.2291 .pred.2292 .fields.2293) (c",
"ons .the-begin.2160 (cons (cons .the-define.2158 (cons .ctor.2291 (cons (cons (.",
"the.2150 (core#quote make-record)) (cons (cons (core#quote quote) (cons .type.22",
"90 (core#quote ()))) (cons (cons (.the.2150 (core#quote vector)) (map (core#lamb",
"da (.field.2294) (core#if (memq (car .field.2294) (cdr .ctor.2291)) (car .field.",
"2294) #undefined)) .fields.2293)) (core#quote ())))) (core#quote ())))) (cons (c",
"ons .the-define.2158 (cons .pred.2292 (cons (cons (.the.2150 (core#quote lambda)",
") (cons (cons (core#quote obj) (core#quote ())) (cons (cons (.the.2150 (core#quo",
"te and)) (cons (cons (.the.2150 (core#quote record?)) (cons (core#quote obj) (co",
"re#quote ()))) (cons (cons (.the.2150 (core#quote eq?)) (cons (cons (.the.2150 (",
"core#quote record-type)) (cons (core#quote obj) (core#quote ()))) (cons (cons (c",
"ore#quote quote) (cons .type.2290 (core#quote ()))) (core#quote ())))) (core#quo",
"te ())))) (core#quote ())))) (core#quote ())))) ((core#lambda () (core#begin (co",
"re#define .loop.2295 (core#lambda (.fields.2296 .pos.2297 .acc.2298) (core#if (n",
"ull? .fields.2296) .acc.2298 ((core#lambda (.field.2299) ((core#lambda (.defs.23",
"00) (.loop.2295 (cdr .fields.2296) (+ .pos.2297 1) (append .defs.2300 .acc.2298)",
")) (cons (cons .the-define.2158 (cons (cons (cadr .field.2299) (cons (core#quote",
" obj) (core#quote ()))) (cons (cons .the-if.2163 (cons (cons .pred.2292 (cons (c",
"ore#quote obj) (core#quote ()))) (cons (cons (.the.2150 (core#quote vector-ref))",
" (cons (cons (.the.2150 (core#quote record-datum)) (cons (core#quote obj) (core#",
"quote ()))) (cons .pos.2297 (core#quote ())))) (cons (cons (.the.2150 (core#quot",
"e error)) (cons (core#quote \"record type mismatch\") (cons (core#quote obj) (cons",
" (cons (core#quote quote) (cons .type.2290 (core#quote ()))) (core#quote ())))))",
" (core#quote ()))))) (core#quote ())))) (core#if (null? (cddr .field.2299)) (cor",
"e#quote ()) (cons (cons .the-define.2158 (cons (cons (car (cddr .field.2299)) (c",
"ons (core#quote obj) (cons (core#quote value) (core#quote ())))) (cons (cons .th",
"e-if.2163 (cons (cons .pred.2292 (cons (core#quote obj) (core#quote ()))) (cons ",
"(cons (.the.2150 (core#quote vector-set!)) (cons (cons (.the.2150 (core#quote re",
"cord-datum)) (cons (core#quote obj) (core#quote ()))) (cons .pos.2297 (cons (cor",
"e#quote value) (core#quote ()))))) (cons (cons (.the.2150 (core#quote error)) (c",
"ons (core#quote \"record type mismatch\") (cons (core#quote obj) (cons (cons (core",
"#quote quote) (cons .type.2290 (core#quote ()))) (core#quote ()))))) (core#quote",
" ()))))) (core#quote ())))) (core#quote ())))))) (car .fields.2296))))) (.loop.2",
"295 .fields.2293 0 (core#quote ()))))))))) (car (cdr .form.2288)) (car (cdr (cdr",
" .form.2288))) (car (cdr (cdr (cdr .form.2288)))) (cdr (cdr (cdr (cdr .form.2288",
"))))))))))))))))))))))))))))))))))))) (.the.2150 (core#quote core#define)) (.the",
".2150 (core#quote core#lambda)) (.the.2150 (core#quote core#begin)) (.the.2150 (",
"core#quote core#quote)) (.the.2150 (core#quote core#set!)) (.the.2150 (core#quot",
"e core#if)) (.the.2150 (core#quote core#define-macro)) (.the.2150 (core#quote de",
"fine)) (.the.2150 (core#quote lambda)) (.the.2150 (core#quote begin)) (.the.2150",
" (core#quote quote)) (.the.2150 (core#quote set!)) (.the.2150 (core#quote if)) (",
".the.2150 (core#quote define-macro)))) (core#lambda (.name.2301 .transformer.230",
"2) (dictionary-set! (macro-objects) .name.2301 .transformer.2302)) (core#lambda ",
"(.var.2303) (make-identifier .var.2303 default-environment)))",
};
static const char boot_compile_rom[][80] = {
"(core#begin (core#define make-identifier #undefined) (core#begin (core#define id",
"entifier? #undefined) (core#begin (core#define identifier=? #undefined) (core#be",
"gin (core#define identifier-name #undefined) (core#begin (core#define identifier",
"-environment #undefined) (core#begin (core#define make-environment #undefined) (",
"core#begin (core#define default-environment #undefined) (core#begin (core#define",
" environment? #undefined) (core#begin (core#define find-identifier #undefined) (",
"core#begin (core#define add-identifier! #undefined) (core#begin (core#define set",
"-identifier! #undefined) (core#begin (core#define macro-objects #undefined) (cor",
"e#begin (core#define compile #undefined) (core#begin (core#define eval #undefine",
"d) (call-with-values (core#lambda () ((core#lambda () (core#begin (core#begin (c",
"ore#define .make-identifier.2304 (core#lambda (.name.2330 .env.2331) (make-recor",
"d (core#quote identifier) (vector .name.2330 .env.2331)))) (core#begin (core#def",
"ine .%identifier?.2305 (core#lambda (.obj.2332) (core#if (record? .obj.2332) (eq",
"? (record-type .obj.2332) (core#quote identifier)) #f))) (core#begin (core#defin",
"e .identifier-environment.2306 (core#lambda (.obj.2333) (core#if (.%identifier?.",
"2305 .obj.2333) (vector-ref (record-datum .obj.2333) 1) (error \"record type mism",
"atch\" .obj.2333 (core#quote identifier))))) (core#define .identifier-name.2307 (",
"core#lambda (.obj.2334) (core#if (.%identifier?.2305 .obj.2334) (vector-ref (rec",
"ord-datum .obj.2334) 0) (error \"record type mismatch\" .obj.2334 (core#quote iden",
"tifier)))))))) (core#begin (core#define .identifier?.2308 (core#lambda (.obj.233",
"5) ((core#lambda (.it.2336) (core#if .it.2336 .it.2336 ((core#lambda (.it.2337) ",
"(core#if .it.2337 .it.2337 #f)) (.%identifier?.2305 .obj.2335)))) (symbol? .obj.",
"2335)))) (core#begin (core#define .identifier=?.2309 (core#lambda (.id1.2338 .id",
"2.2339) (core#if (core#if (symbol? .id1.2338) (symbol? .id2.2339) #f) (eq? .id1.",
"2338 .id2.2339) (core#if (core#if (.%identifier?.2305 .id1.2338) (.%identifier?.",
"2305 .id2.2339) #f) (eq? (.find-identifier.2316 (.identifier-name.2307 .id1.2338",
") (.identifier-environment.2306 .id1.2338)) (.find-identifier.2316 (.identifier-",
"name.2307 .id2.2339) (.identifier-environment.2306 .id2.2339))) #f)))) (core#beg",
"in (core#set! equal? ((core#lambda (.e?.2340) (core#lambda (.x.2341 .y.2342) (co",
"re#if (.%identifier?.2305 .x.2341) (.identifier=?.2309 .x.2341 .y.2342) (.e?.234",
"0 .x.2341 .y.2342)))) equal?)) (core#begin (core#begin (core#define .%make-envir",
"onment.2310 (core#lambda (.parent.2343 .prefix.2344 .binding.2345) (make-record ",
"(core#quote environment) (vector .parent.2343 .prefix.2344 .binding.2345)))) (co",
"re#begin (core#define .environment?.2311 (core#lambda (.obj.2346) (core#if (reco",
"rd? .obj.2346) (eq? (record-type .obj.2346) (core#quote environment)) #f))) (cor",
"e#begin (core#define .environment-binding.2312 (core#lambda (.obj.2347) (core#if",
" (.environment?.2311 .obj.2347) (vector-ref (record-datum .obj.2347) 2) (error \"",
"record type mismatch\" .obj.2347 (core#quote environment))))) (core#begin (core#d",
"efine .environment-prefix.2313 (core#lambda (.obj.2348) (core#if (.environment?.",
"2311 .obj.2348) (vector-ref (record-datum .obj.2348) 1) (error \"record type mism",
"atch\" .obj.2348 (core#quote environment))))) (core#define .environment-parent.23",
"14 (core#lambda (.obj.2349) (core#if (.environment?.2311 .obj.2349) (vector-ref ",
"(record-datum .obj.2349) 0) (error \"record type mismatch\" .obj.2349 (core#quote ",
"environment))))))))) (core#begin (core#define .search-scope.2315 (core#lambda (.",
"id.2350 .env.2351) ((.environment-binding.2312 .env.2351) .id.2350))) (core#begi",
"n (core#define .find-identifier.2316 (core#lambda (.id.2352 .env.2353) ((core#la",
"mbda (.it.2354) (core#if .it.2354 .it.2354 ((core#lambda (.it.2355) (core#if .it",
".2355 .it.2355 #f)) ((core#lambda (.parent.2356) (core#if .parent.2356 (.find-id",
"entifier.2316 .id.2352 .parent.2356) (core#if (symbol? .id.2352) (.add-identifie",
"r!.2317 .id.2352 .env.2353) (.find-identifier.2316 (.identifier-name.2307 .id.23",
"52) (.identifier-environment.2306 .id.2352))))) (.environment-parent.2314 .env.2",
"353))))) (.search-scope.2315 .id.2352 .env.2353)))) (core#begin (core#define .ad",
"d-identifier!.2317 ((core#lambda (.uniq.2357) (core#lambda (.id.2358 .env.2359) ",
"((core#lambda (.it.2360) (core#if .it.2360 .it.2360 ((core#lambda (.it.2361) (co",
"re#if .it.2361 .it.2361 #f)) (core#if (core#if (not (.environment-parent.2314 .e",
"nv.2359)) (symbol? .id.2358) #f) (string->symbol (string-append (.environment-pr",
"efix.2313 .env.2359) (symbol->string .id.2358))) ((core#lambda (.uid.2362) (core",
"#begin (.set-identifier!.2318 .id.2358 .uid.2362 .env.2359) .uid.2362)) (.uniq.2",
"357 .id.2358)))))) (.search-scope.2315 .id.2358 .env.2359)))) ((core#lambda (.n.",
"2363) (core#lambda (.id.2364) ((core#lambda (.m.2365) (core#begin (core#set! .n.",
"2363 (+ .n.2363 1)) (string->symbol (string-append \".\" (symbol->string ((core#la",
"mbda () (core#begin (core#define .loop.2366 (core#lambda (.id.2367) (core#if (sy",
"mbol? .id.2367) .id.2367 (.loop.2366 (.identifier-name.2307 .id.2367))))) (.loop",
".2366 .id.2364))))) \".\" (number->string .m.2365))))) .n.2363))) 0))) (core#begin",
" (core#define .set-identifier!.2318 (core#lambda (.id.2368 .uid.2369 .env.2370) ",
"((.environment-binding.2312 .env.2370) .id.2368 .uid.2369))) (core#begin (core#d",
"efine .make-environment.2319 (core#lambda (.prefix.2371) (.%make-environment.231",
"0 #f (symbol->string .prefix.2371) (make-ephemeron-table)))) (core#begin (core#d",
"efine .default-environment.2320 ((core#lambda (.env.2372) (core#begin (for-each ",
"(core#lambda (.x.2373) (.set-identifier!.2318 .x.2373 .x.2373 .env.2372)) (core#",
"quote (core#define core#set! core#quote core#lambda core#if core#begin core#defi",
"ne-macro))) .env.2372)) (.make-environment.2319 (string->symbol \"\")))) (core#beg",
"in (core#define .extend-environment.2321 (core#lambda (.parent.2374) (.%make-env",
"ironment.2310 .parent.2374 #f (make-ephemeron-table)))) (core#begin (core#define",
" .global-macro-table.2322 (make-dictionary)) (core#begin (core#define .find-macr",
"o.2323 (core#lambda (.uid.2375) (core#if (dictionary-has? .global-macro-table.23",
"22 .uid.2375) (dictionary-ref .global-macro-table.2322 .uid.2375) #f))) (core#be",
"gin (core#define .add-macro!.2324 (core#lambda (.uid.2376 .expander.2377) (dicti",
"onary-set! .global-macro-table.2322 .uid.2376 .expander.2377))) (core#begin (cor",
"e#define .shadow-macro!.2325 (core#lambda (.uid.2378) (core#if (dictionary-has? ",
".global-macro-table.2322 .uid.2378) (dictionary-delete! .global-macro-table.2322",
" .uid.2378) #undefined))) (core#begin (core#define .macro-objects.2326 (core#lam",
"bda () .global-macro-table.2322)) (core#begin (core#define .expand.2327 ((core#l",
"ambda (.task-queue.2379) (core#begin (core#define .queue.2380 (core#lambda (.tas",
"k.2393) ((core#lambda (.tmp.2394) (core#begin (.task-queue.2379 (cons (cons .tmp",
".2394 .task.2393) (.task-queue.2379))) .tmp.2394)) (cons #f #f)))) (core#begin (",
"core#define .run-all.2381 (core#lambda () (for-each (core#lambda (.x.2395) ((cor",
"e#lambda (.task.2396 .skelton.2397) ((core#lambda (.x.2398) (core#begin (set-car",
"! .skelton.2397 (car .x.2398)) (set-cdr! .skelton.2397 (cdr .x.2398)))) (.task.2",
"396))) (cdr .x.2395) (car .x.2395))) (reverse (.task-queue.2379))))) (core#begin",
" (core#define .caddr.2382 (core#lambda (.x.2399) (car (cddr .x.2399)))) (core#be",
"gin (core#define .map*.2383 (core#lambda (.proc.2400 .list*.2401) (core#if (null",
"? .list*.2401) .list*.2401 (core#if (pair? .list*.2401) (cons (.proc.2400 (car .",
"list*.2401)) (.map*.2383 .proc.2400 (cdr .list*.2401))) (.proc.2400 .list*.2401)",
")))) (core#begin (core#define .literal?.2384 (core#lambda (.x.2402) (not ((core#",
"lambda (.it.2403) (core#if .it.2403 .it.2403 ((core#lambda (.it.2404) (core#if .",
"it.2404 .it.2404 #f)) (pair? .x.2402)))) (.identifier?.2308 .x.2402))))) (core#b",
"egin (core#define .call?.2385 (core#lambda (.x.2405) (core#if (list? .x.2405) (c",
"ore#if (not (null? .x.2405)) (.identifier?.2308 (car .x.2405)) #f) #f))) (core#b",
"egin (core#define .expand-variable.2386 (core#lambda (.var.2406 .env.2407) ((cor",
"e#lambda (.x.2408) ((core#lambda (.m.2409) (core#if .m.2409 (.expand-node.2391 (",
".m.2409 .var.2406 .env.2407) .env.2407) .x.2408)) (.find-macro.2323 .x.2408))) (",
".find-identifier.2316 .var.2406 .env.2407)))) (core#begin (core#define .expand-q",
"uote.2387 (core#lambda (.obj.2410) (cons (core#quote core#quote) (cons .obj.2410",
" (core#quote ()))))) (core#begin (core#define .expand-define.2388 (core#lambda (",
".var.2411 .form.2412 .env.2413) ((core#lambda (.uid.2414) (core#begin (.shadow-m",
"acro!.2325 .uid.2414) (cons (core#quote core#define) (cons .uid.2414 (cons (.exp",
"and-node.2391 .form.2412 .env.2413) (core#quote ())))))) (.add-identifier!.2317 ",
".var.2411 .env.2413)))) (core#begin (core#define .expand-lambda.2389 (core#lambd",
"a (.args.2415 .body.2416 .env.2417) ((core#lambda (.env.2418) ((core#lambda (.ar",
"gs.2419) (with-dynamic-environment (list (cons .task-queue.2379 (core#quote ()))",
") (core#lambda () ((core#lambda (.body.2420) (core#begin (.run-all.2381) (cons (",
"core#quote core#lambda) (cons .args.2419 (cons .body.2420 (core#quote ())))))) (",
".expand-node.2391 .body.2416 .env.2418))))) (.map*.2383 (core#lambda (.var.2421)",
" (.add-identifier!.2317 .var.2421 .env.2418)) .args.2415))) (.extend-environment",
".2321 .env.2417)))) (core#begin (core#define .expand-define-macro.2390 (core#lam",
"bda (.var.2422 .transformer.2423 .env.2424) ((core#lambda (.uid.2425) ((core#lam",
"bda (.expander.2426) (core#begin (.add-macro!.2324 .uid.2425 .expander.2426) #un",
"defined)) (load (.expand.2392 .transformer.2423 .env.2424)))) (.add-identifier!.",
"2317 .var.2422 .env.2424)))) (core#begin (core#define .expand-node.2391 (core#la",
"mbda (.expr.2427 .env.2428) (core#if (.literal?.2384 .expr.2427) .expr.2427 (cor",
"e#if (.identifier?.2308 .expr.2427) (.expand-variable.2386 .expr.2427 .env.2428)",
" (core#if (.call?.2385 .expr.2427) ((core#lambda (.functor.2429) ((core#lambda (",
".key.2430) (core#if ((core#lambda (.it.2431) (core#if .it.2431 .it.2431 #f)) (eq",
"v? .key.2430 (core#quote core#quote))) (.expand-quote.2387 (cadr .expr.2427)) (c",
"ore#if ((core#lambda (.it.2432) (core#if .it.2432 .it.2432 #f)) (eqv? .key.2430 ",
"(core#quote core#define))) (.expand-define.2388 (cadr .expr.2427) (.caddr.2382 .",
"expr.2427) .env.2428) (core#if ((core#lambda (.it.2433) (core#if .it.2433 .it.24",
"33 #f)) (eqv? .key.2430 (core#quote core#lambda))) (.queue.2380 (core#lambda () ",
"(.expand-lambda.2389 (cadr .expr.2427) (.caddr.2382 .expr.2427) .env.2428))) (co",
"re#if ((core#lambda (.it.2434) (core#if .it.2434 .it.2434 #f)) (eqv? .key.2430 (",
"core#quote core#define-macro))) (.expand-define-macro.2390 (cadr .expr.2427) (.c",
"addr.2382 .expr.2427) .env.2428) (core#if #t ((core#lambda (.m.2435) (core#if .m",
".2435 (.expand-node.2391 (.m.2435 .expr.2427 .env.2428) .env.2428) (map (core#la",
"mbda (.x.2436) (.expand-node.2391 .x.2436 .env.2428)) .expr.2427))) (.find-macro",
".2323 .functor.2429)) #undefined)))))) .functor.2429)) (.find-identifier.2316 (c",
"ar .expr.2427) .env.2428)) (core#if (list? .expr.2427) (map (core#lambda (.x.243",
"7) (.expand-node.2391 .x.2437 .env.2428)) .expr.2427) (error \"invalid expression",
"\" .expr.2427))))))) (core#begin (core#define .expand.2392 (core#lambda (.expr.24",
"38 .env.2439) ((core#lambda (.x.2440) (core#begin (.run-all.2381) .x.2440)) (.ex",
"pand-node.2391 .expr.2438 .env.2439)))) .expand.2392)))))))))))))) (make-paramet",
"er (core#quote ())))) (core#begin (core#define .compile.2328 (core#lambda (.expr",
".2441 . .env.2442) (.expand.2327 .expr.2441 (core#if (null? .env.2442) .default-",
"environment.2320 (car .env.2442))))) (core#begin (core#define .eval.2329 (core#l",
"ambda (.expr.2443 . .env.2444) (load (.compile.2328 .expr.2443 (core#if (null? .",
"env.2444) .default-environment.2320 (car .env.2444)))))) (values .make-identifie",
"r.2304 .identifier?.2308 .identifier=?.2309 .identifier-name.2307 .identifier-en",
"vironment.2306 .make-environment.2319 .default-environment.2320 .environment?.23",
"11 .find-identifier.2316 .add-identifier!.2317 .set-identifier!.2318 .macro-obje",
"cts.2326 .compile.2328 .eval.2329)))))))))))))))))))))))) (core#lambda (.make-id",
"entifier.2445 .identifier?.2446 .identifier=?.2447 .identifier-name.2448 .identi",
"fier-environment.2449 .make-environment.2450 .default-environment.2451 .environm",
"ent?.2452 .find-identifier.2453 .add-identifier!.2454 .set-identifier!.2455 .mac",
"ro-objects.2456 .compile.2457 .eval.2458) (core#begin (core#set! make-identifier",
" .make-identifier.2445) (core#begin (core#set! identifier? .identifier?.2446) (c",
"ore#begin (core#set! identifier=? .identifier=?.2447) (core#begin (core#set! ide",
"ntifier-name .identifier-name.2448) (core#begin (core#set! identifier-environmen",
"t .identifier-environment.2449) (core#begin (core#set! make-environment .make-en",
"vironment.2450) (core#begin (core#set! default-environment .default-environment.",
"2451) (core#begin (core#set! environment? .environment?.2452) (core#begin (core#",
"set! find-identifier .find-identifier.2453) (core#begin (core#set! add-identifie",
"r! .add-identifier!.2454) (core#begin (core#set! set-identifier! .set-identifier",
"!.2455) (core#begin (core#set! macro-objects .macro-objects.2456) (core#begin (c",
"ore#set! compile .compile.2457) (core#set! eval .eval.2458))))))))))))))))))))))",
"))))))))",
2017-04-03 09:09:19 -04:00
};
#if PIC_USE_LIBRARY
static const char boot_library_rom[][80] = {
2017-04-03 14:55:23 -04:00
"(core#begin (core#define current-library #undefined) (core#begin (core#define fi",
"nd-library #undefined) (core#begin (core#define make-library #undefined) (core#b",
"egin (core#define library-environment #undefined) (core#begin (core#define libra",
"ry-exports #undefined) (core#begin (core#define library-import #undefined) (core",
"#begin (core#define library-export #undefined) (call-with-values (core#lambda ()",
2017-04-04 01:54:58 -04:00
" ((core#lambda () (core#begin (core#define .mangle.2459 (core#lambda (.name.2468",
") (core#begin (core#if (null? .name.2468) (error \"library name should be a list ",
"of at least one symbols\" .name.2468) #undefined) (core#begin (core#define .->str",
"ing.2469 (core#lambda (.n.2471) (core#if (symbol? .n.2471) ((core#lambda (.str.2",
"472) (core#begin (string-for-each (core#lambda (.c.2473) (core#if ((core#lambda ",
"(.it.2474) (core#if .it.2474 .it.2474 ((core#lambda (.it.2475) (core#if .it.2475",
" .it.2475 #f)) (char=? .c.2473 #\\:)))) (char=? .c.2473 #\\.)) (error \"elements of",
" library name may not contain '.' or ':'\" .n.2471) #undefined)) .str.2472) .str.",
"2472)) (symbol->string .n.2471)) (core#if (core#if (number? .n.2471) (core#if (e",
"xact? .n.2471) (<= 0 .n.2471) #f) #f) (number->string .n.2471) (error \"symbol or",
" non-negative integer is required\" .n.2471))))) (core#begin (core#define .join.2",
"470 (core#lambda (.strs.2476 .delim.2477) ((core#lambda () (core#begin (core#def",
"ine .loop.2478 (core#lambda (.res.2479 .strs.2480) (core#if (null? .strs.2480) .",
"res.2479 (.loop.2478 (string-append .res.2479 .delim.2477 (car .strs.2480)) (cdr",
" .strs.2480))))) (.loop.2478 (car .strs.2476) (cdr .strs.2476))))))) (core#if (s",
"ymbol? .name.2468) .name.2468 (string->symbol (.join.2470 (map .->string.2469 .n",
"ame.2468) \".\")))))))) (core#begin (core#define .current-library.2460 (make-param",
"eter (core#quote (picrin user)) .mangle.2459)) (core#begin (core#define .*librar",
"ies*.2461 (make-dictionary)) (core#begin (core#define .find-library.2462 (core#l",
"ambda (.name.2481) (dictionary-has? .*libraries*.2461 (.mangle.2459 .name.2481))",
")) (core#begin (core#define .make-library.2463 (core#lambda (.name.2482) ((core#",
"lambda (.name.2483) ((core#lambda (.env.2484 .exports.2485) (core#begin (set-ide",
"ntifier! (core#quote define-library) (core#quote define-library) .env.2484) (cor",
"e#begin (set-identifier! (core#quote import) (core#quote import) .env.2484) (cor",
"e#begin (set-identifier! (core#quote export) (core#quote export) .env.2484) (cor",
2017-04-03 14:55:23 -04:00
"e#begin (set-identifier! (core#quote cond-expand) (core#quote cond-expand) .env.",
2017-04-04 01:54:58 -04:00
"2484) (dictionary-set! .*libraries*.2461 .name.2483 (cons .env.2484 .exports.248",
"5))))))) (make-environment (string->symbol (string-append (symbol->string .name.",
"2483) \":\"))) (make-dictionary))) (.mangle.2459 .name.2482)))) (core#begin (core#",
"define .library-environment.2464 (core#lambda (.name.2486) (car (dictionary-ref ",
".*libraries*.2461 (.mangle.2459 .name.2486))))) (core#begin (core#define .librar",
"y-exports.2465 (core#lambda (.name.2487) (cdr (dictionary-ref .*libraries*.2461 ",
"(.mangle.2459 .name.2487))))) (core#begin (core#define .library-import.2466 (cor",
"e#lambda (.name.2488 .sym.2489 .alias.2490) ((core#lambda (.uid.2491) ((core#lam",
"bda (.env.2492) (set-identifier! .alias.2490 .uid.2491 .env.2492)) (.library-env",
"ironment.2464 (.current-library.2460)))) (dictionary-ref (.library-exports.2465 ",
".name.2488) .sym.2489)))) (core#begin (core#define .library-export.2467 (core#la",
"mbda (.sym.2493 .alias.2494) ((core#lambda (.env.2495 .exports.2496) (dictionary",
"-set! .exports.2496 .alias.2494 (find-identifier .sym.2493 .env.2495))) (.librar",
"y-environment.2464 (.current-library.2460)) (.library-exports.2465 (.current-lib",
"rary.2460))))) (core#begin ((core#lambda (.define-transformer.2497) (core#begin ",
"(.define-transformer.2497 (core#quote define-library) (core#lambda (.form.2498 .",
"_.2499) ((core#lambda (.name.2500 .body.2501) (core#begin ((core#lambda (.it.250",
"2) (core#if .it.2502 .it.2502 ((core#lambda (.it.2503) (core#if .it.2503 .it.250",
"3 #f)) (.make-library.2463 .name.2500)))) (.find-library.2462 .name.2500)) (with",
"-dynamic-environment (list (cons .current-library.2460 .name.2500)) (core#lambda",
" () (for-each (core#lambda (.expr.2504) (eval .expr.2504 .name.2500)) .body.2501",
"))))) (cadr .form.2498) (cddr .form.2498)))) (core#begin (.define-transformer.24",
"97 (core#quote cond-expand) (core#lambda (.form.2505 ._.2506) ((core#lambda (.te",
"st.2507) (core#begin (core#set! .test.2507 (core#lambda (.form.2508) ((core#lamb",
"da (.it.2509) (core#if .it.2509 .it.2509 ((core#lambda (.it.2510) (core#if .it.2",
"510 .it.2510 ((core#lambda (.it.2511) (core#if .it.2511 .it.2511 #f)) (core#if (",
"pair? .form.2508) ((core#lambda (.key.2512) (core#if ((core#lambda (.it.2513) (c",
"ore#if .it.2513 .it.2513 #f)) (eqv? .key.2512 (core#quote library))) (.find-libr",
"ary.2462 (cadr .form.2508)) (core#if ((core#lambda (.it.2514) (core#if .it.2514 ",
".it.2514 #f)) (eqv? .key.2512 (core#quote not))) (not (.test.2507 (cadr .form.25",
"08))) (core#if ((core#lambda (.it.2515) (core#if .it.2515 .it.2515 #f)) (eqv? .k",
"ey.2512 (core#quote and))) ((core#lambda () (core#begin (core#define .loop.2516 ",
"(core#lambda (.form.2517) ((core#lambda (.it.2518) (core#if .it.2518 .it.2518 ((",
"core#lambda (.it.2519) (core#if .it.2519 .it.2519 #f)) (core#if (.test.2507 (car",
" .form.2517)) (.loop.2516 (cdr .form.2517)) #f)))) (null? .form.2517)))) (.loop.",
"2516 (cdr .form.2508))))) (core#if ((core#lambda (.it.2520) (core#if .it.2520 .i",
"t.2520 #f)) (eqv? .key.2512 (core#quote or))) ((core#lambda () (core#begin (core",
"#define .loop.2521 (core#lambda (.form.2522) (core#if (pair? .form.2522) ((core#",
"lambda (.it.2523) (core#if .it.2523 .it.2523 ((core#lambda (.it.2524) (core#if .",
"it.2524 .it.2524 #f)) (.loop.2521 (cdr .form.2522))))) (.test.2507 (car .form.25",
"22))) #f))) (.loop.2521 (cdr .form.2508))))) (core#if #t #f #undefined)))))) (ca",
"r .form.2508)) #f)))) (core#if (symbol? .form.2508) (memq .form.2508 (features))",
" #f)))) (eq? .form.2508 (core#quote else))))) ((core#lambda () (core#begin (core",
"#define .loop.2525 (core#lambda (.clauses.2526) (core#if (null? .clauses.2526) #",
"undefined (core#if (.test.2507 (caar .clauses.2526)) (cons (make-identifier (cor",
"e#quote begin) default-environment) (append (cdar .clauses.2526) (core#quote ())",
")) (.loop.2525 (cdr .clauses.2526)))))) (.loop.2525 (cdr .form.2505))))))) #unde",
"fined))) (core#begin (.define-transformer.2497 (core#quote import) (core#lambda ",
"(.form.2527 ._.2528) ((core#lambda (.caddr.2529 .prefix.2530 .getlib.2531) ((cor",
"e#lambda (.extract.2532 .collect.2533) (core#begin (core#set! .extract.2532 (cor",
"e#lambda (.spec.2534) ((core#lambda (.key.2535) (core#if ((core#lambda (.it.2536",
") (core#if .it.2536 .it.2536 ((core#lambda (.it.2537) (core#if .it.2537 .it.2537",
" ((core#lambda (.it.2538) (core#if .it.2538 .it.2538 ((core#lambda (.it.2539) (c",
"ore#if .it.2539 .it.2539 #f)) (eqv? .key.2535 (core#quote except))))) (eqv? .key",
".2535 (core#quote prefix))))) (eqv? .key.2535 (core#quote rename))))) (eqv? .key",
".2535 (core#quote only))) (.extract.2532 (cadr .spec.2534)) (core#if #t (.getlib",
".2531 .spec.2534) #undefined))) (car .spec.2534)))) (core#begin (core#set! .coll",
"ect.2533 (core#lambda (.spec.2540) ((core#lambda (.key.2541) (core#if ((core#lam",
"bda (.it.2542) (core#if .it.2542 .it.2542 #f)) (eqv? .key.2541 (core#quote only)",
")) ((core#lambda (.alist.2543) (map (core#lambda (.var.2544) (assq .var.2544 .al",
"ist.2543)) (cddr .spec.2540))) (.collect.2533 (cadr .spec.2540))) (core#if ((cor",
"e#lambda (.it.2545) (core#if .it.2545 .it.2545 #f)) (eqv? .key.2541 (core#quote ",
"rename))) ((core#lambda (.alist.2546 .renames.2547) (map (core#lambda (.s.2548) ",
"((core#lambda (.it.2549) (core#if .it.2549 .it.2549 ((core#lambda (.it.2550) (co",
"re#if .it.2550 .it.2550 #f)) .s.2548))) (assq (car .s.2548) .renames.2547))) .al",
"ist.2546)) (.collect.2533 (cadr .spec.2540)) (map (core#lambda (.x.2551) (cons (",
"car .x.2551) (cadr .x.2551))) (cddr .spec.2540))) (core#if ((core#lambda (.it.25",
"52) (core#if .it.2552 .it.2552 #f)) (eqv? .key.2541 (core#quote prefix))) ((core",
"#lambda (.alist.2553) (map (core#lambda (.s.2554) (cons (.prefix.2530 (.caddr.25",
"29 .spec.2540) (car .s.2554)) (cdr .s.2554))) .alist.2553)) (.collect.2533 (cadr",
" .spec.2540))) (core#if ((core#lambda (.it.2555) (core#if .it.2555 .it.2555 #f))",
" (eqv? .key.2541 (core#quote except))) ((core#lambda (.alist.2556) ((core#lambda",
" () (core#begin (core#define .loop.2557 (core#lambda (.alist.2558) (core#if (nul",
"l? .alist.2558) (core#quote ()) (core#if (memq (caar .alist.2558) (cddr .spec.25",
"40)) (.loop.2557 (cdr .alist.2558)) (cons (car .alist.2558) (.loop.2557 (cdr .al",
"ist.2558))))))) (.loop.2557 .alist.2556))))) (.collect.2533 (cadr .spec.2540))) ",
"(core#if #t (dictionary-map (core#lambda (.x.2559) (cons .x.2559 .x.2559)) (.lib",
"rary-exports.2465 (.getlib.2531 .spec.2540))) #undefined)))))) (car .spec.2540))",
")) ((core#lambda (.import.2560) (core#begin (core#set! .import.2560 (core#lambda",
" (.spec.2561) ((core#lambda (.lib.2562 .alist.2563) (for-each (core#lambda (.slo",
"t.2564) (.library-import.2466 .lib.2562 (cdr .slot.2564) (car .slot.2564))) .ali",
"st.2563)) (.extract.2532 .spec.2561) (.collect.2533 .spec.2561)))) (for-each .im",
"port.2560 (cdr .form.2527)))) #undefined)))) #undefined #undefined)) (core#lambd",
"a (.x.2565) (car (cdr (cdr .x.2565)))) (core#lambda (.prefix.2566 .symbol.2567) ",
"(string->symbol (string-append (symbol->string .prefix.2566) (symbol->string .sy",
"mbol.2567)))) (core#lambda (.name.2568) (core#if (.find-library.2462 .name.2568)",
" .name.2568 (error \"library not found\" .name.2568)))))) (.define-transformer.249",
"7 (core#quote export) (core#lambda (.form.2569 ._.2570) ((core#lambda (.collect.",
"2571 .export.2572) (core#begin (core#set! .collect.2571 (core#lambda (.spec.2573",
") (core#if (symbol? .spec.2573) (cons .spec.2573 .spec.2573) (core#if (core#if (",
"list? .spec.2573) (core#if (= (length .spec.2573) 3) (eq? (car .spec.2573) (core",
"#quote rename)) #f) #f) (cons (list-ref .spec.2573 1) (list-ref .spec.2573 2)) (",
"error \"malformed export\"))))) (core#begin (core#set! .export.2572 (core#lambda (",
".spec.2574) ((core#lambda (.slot.2575) (.library-export.2467 (car .slot.2575) (c",
"dr .slot.2575))) (.collect.2571 .spec.2574)))) (for-each .export.2572 (cdr .form",
".2569))))) #undefined #undefined))))))) (core#lambda (.name.2576 .macro.2577) (d",
"ictionary-set! (macro-objects) .name.2576 .macro.2577))) (core#begin ((core#lamb",
"da () (core#begin (.make-library.2463 (core#quote (picrin base))) (core#begin (s",
"et-car! (dictionary-ref .*libraries*.2461 (.mangle.2459 (core#quote (picrin base",
")))) default-environment) (core#begin ((core#lambda (.exports.2578) ((core#lambd",
"a (.export-keyword.2579) ((core#lambda () (core#begin (for-each .export-keyword.",
"2579 (core#quote (define lambda quote set! if begin define-macro let let* letrec",
2017-04-03 14:55:23 -04:00
" letrec* let-values let*-values define-values quasiquote unquote unquote-splicin",
2017-04-04 01:54:58 -04:00
"g and or cond case else => do when unless parameterize define-record-type))) (co",
"re#begin (.export-keyword.2579 (core#quote boolean?)) (dictionary-for-each .expo",
"rt-keyword.2579 (global-objects))))))) (core#lambda (.keyword.2580) (dictionary-",
"set! .exports.2578 .keyword.2580 .keyword.2580)))) (.library-exports.2465 (core#",
"quote (picrin base)))) (core#begin (core#set! eval ((core#lambda (.e.2581) (core",
"#lambda (.expr.2582 . .lib.2583) ((core#lambda (.lib.2584) (with-dynamic-environ",
"ment (list (cons .current-library.2460 .lib.2584)) (core#lambda () (.e.2581 .exp",
"r.2582 (.library-environment.2464 .lib.2584))))) (core#if (null? .lib.2583) (.cu",
"rrent-library.2460) (car .lib.2583))))) eval)) (.make-library.2463 (core#quote (",
"picrin user))))))))) (values .current-library.2460 .find-library.2462 .make-libr",
"ary.2463 .library-environment.2464 .library-exports.2465 .library-import.2466 .l",
"ibrary-export.2467))))))))))))))) (core#lambda (.current-library.2585 .find-libr",
"ary.2586 .make-library.2587 .library-environment.2588 .library-exports.2589 .lib",
"rary-import.2590 .library-export.2591) (core#begin (core#set! current-library .c",
"urrent-library.2585) (core#begin (core#set! find-library .find-library.2586) (co",
"re#begin (core#set! make-library .make-library.2587) (core#begin (core#set! libr",
"ary-environment .library-environment.2588) (core#begin (core#set! library-export",
"s .library-exports.2589) (core#begin (core#set! library-import .library-import.2",
"590) (core#set! library-export .library-export.2591))))))))))))))))",
2015-01-31 07:14:14 -05:00
};
2017-04-03 09:09:19 -04:00
#endif
2014-09-08 10:31:04 -04:00
2016-03-03 04:59:07 -05:00
void
pic_boot(pic_state *pic)
{
2017-04-04 01:54:58 -04:00
pic_load_native(pic, &boot_compile_rom[0][0]);
2017-04-03 11:52:59 -04:00
pic_load_native(pic, &boot_rom[0][0]);
2017-04-03 09:09:19 -04:00
#if PIC_USE_LIBRARY
2017-04-03 11:52:59 -04:00
pic_load_native(pic, &boot_library_rom[0][0]);
2017-04-03 09:09:19 -04:00
#endif
2016-03-03 04:59:07 -05:00
}