Mercurial > urweb
comparison src/mono_util.sml @ 1073:b2311dfb3158
Initializers and setval
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sun, 13 Dec 2009 14:20:41 -0500 |
parents | 217eb87dde31 |
children | 0657e5adc938 |
comparison
equal
deleted
inserted
replaced
1072:9001966ae1c8 | 1073:b2311dfb3158 |
---|---|
338 (EDml e', loc)) | 338 (EDml e', loc)) |
339 | ENextval e => | 339 | ENextval e => |
340 S.map2 (mfe ctx e, | 340 S.map2 (mfe ctx e, |
341 fn e' => | 341 fn e' => |
342 (ENextval e', loc)) | 342 (ENextval e', loc)) |
343 | ESetval (e1, e2) => | |
344 S.bind2 (mfe ctx e1, | |
345 fn e1' => | |
346 S.map2 (mfe ctx e2, | |
347 fn e2' => | |
348 (ESetval (e1', e2'), loc))) | |
343 | EUnurlify (e, t) => | 349 | EUnurlify (e, t) => |
344 S.bind2 (mfe ctx e, | 350 S.bind2 (mfe ctx e, |
345 fn e' => | 351 fn e' => |
346 S.map2 (mft t, | 352 S.map2 (mft t, |
347 fn t' => | 353 fn t' => |
520 (DView (s, xts, e'), loc)) | 526 (DView (s, xts, e'), loc)) |
521 | DDatabase _ => S.return2 dAll | 527 | DDatabase _ => S.return2 dAll |
522 | DJavaScript _ => S.return2 dAll | 528 | DJavaScript _ => S.return2 dAll |
523 | DCookie _ => S.return2 dAll | 529 | DCookie _ => S.return2 dAll |
524 | DStyle _ => S.return2 dAll | 530 | DStyle _ => S.return2 dAll |
531 | DInitializer e => | |
532 S.map2 (mfe ctx e, | |
533 fn e' => | |
534 (DInitializer e', loc)) | |
525 | 535 |
526 and mfvi ctx (x, n, t, e, s) = | 536 and mfvi ctx (x, n, t, e, s) = |
527 S.bind2 (mft t, | 537 S.bind2 (mft t, |
528 fn t' => | 538 fn t' => |
529 S.map2 (mfe ctx e, | 539 S.map2 (mfe ctx e, |
606 | DView _ => ctx | 616 | DView _ => ctx |
607 | DDatabase _ => ctx | 617 | DDatabase _ => ctx |
608 | DJavaScript _ => ctx | 618 | DJavaScript _ => ctx |
609 | DCookie _ => ctx | 619 | DCookie _ => ctx |
610 | DStyle _ => ctx | 620 | DStyle _ => ctx |
621 | DInitializer _ => ctx | |
611 in | 622 in |
612 S.map2 (mff ctx' ds', | 623 S.map2 (mff ctx' ds', |
613 fn ds' => | 624 fn ds' => |
614 d' :: ds') | 625 d' :: ds') |
615 end) | 626 end) |
658 | DSequence _ => count | 669 | DSequence _ => count |
659 | DView _ => count | 670 | DView _ => count |
660 | DDatabase _ => count | 671 | DDatabase _ => count |
661 | DJavaScript _ => count | 672 | DJavaScript _ => count |
662 | DCookie _ => count | 673 | DCookie _ => count |
663 | DStyle _ => count) 0 | 674 | DStyle _ => count |
675 | DInitializer _ => count) 0 | |
664 | 676 |
665 end | 677 end |
666 | 678 |
667 end | 679 end |