Mercurial > urweb
comparison src/urweb.grm @ 720:acb8537f58f0
Stop tracking CSS classes in XML types
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sun, 12 Apr 2009 12:31:54 -0400 |
parents | 5c099b1308ae |
children | 9864b64b1700 |
comparison
equal
deleted
inserted
replaced
719:5c099b1308ae | 720:acb8537f58f0 |
---|---|
449 val c = (CAbs (SYMBOL2, SOME kind, cexp), loc) | 449 val c = (CAbs (SYMBOL2, SOME kind, cexp), loc) |
450 in | 450 in |
451 [(DClass (SYMBOL1, kind, c), s (CLASSleft, cexpright))] | 451 [(DClass (SYMBOL1, kind, c), s (CLASSleft, cexpright))] |
452 end) | 452 end) |
453 | COOKIE SYMBOL COLON cexp ([(DCookie (SYMBOL, cexp), s (COOKIEleft, cexpright))]) | 453 | COOKIE SYMBOL COLON cexp ([(DCookie (SYMBOL, cexp), s (COOKIEleft, cexpright))]) |
454 | STYLE SYMBOL COLON cexp ([(DStyle (SYMBOL, cexp), s (STYLEleft, cexpright))]) | 454 | STYLE SYMBOL ([(DStyle SYMBOL, s (STYLEleft, SYMBOLright))]) |
455 | 455 |
456 kopt : (NONE) | 456 kopt : (NONE) |
457 | DCOLON kind (SOME kind) | 457 | DCOLON kind (SOME kind) |
458 | 458 |
459 dargs : ([]) | 459 dargs : ([]) |
706 val t = (CApp ((CVar (["Basis"], "http_cookie"), loc), | 706 val t = (CApp ((CVar (["Basis"], "http_cookie"), loc), |
707 entable cexp), loc) | 707 entable cexp), loc) |
708 in | 708 in |
709 (SgiVal (SYMBOL, t), loc) | 709 (SgiVal (SYMBOL, t), loc) |
710 end) | 710 end) |
711 | STYLE SYMBOL COLON cexp (let | 711 | STYLE SYMBOL (let |
712 val loc = s (STYLEleft, cexpright) | 712 val loc = s (STYLEleft, SYMBOLright) |
713 val t = (CApp ((CVar (["Basis"], "css_class"), loc), | 713 val t = (CVar (["Basis"], "css_class"), loc) |
714 cexp), loc) | |
715 in | 714 in |
716 (SgiVal (SYMBOL, t), loc) | 715 (SgiVal (SYMBOL, t), loc) |
717 end) | 716 end) |
718 | 717 |
719 sgis : ([]) | 718 sgis : ([]) |
1206 | ident EQ eexp ([(ident, eexp)]) | 1205 | ident EQ eexp ([(ident, eexp)]) |
1207 | ident EQ eexp COMMA rexp ((ident, eexp) :: rexp) | 1206 | ident EQ eexp COMMA rexp ((ident, eexp) :: rexp) |
1208 | 1207 |
1209 xml : xmlOne xml (let | 1208 xml : xmlOne xml (let |
1210 val pos = s (xmlOneleft, xmlright) | 1209 val pos = s (xmlOneleft, xmlright) |
1211 val e = (EVar (["Basis"], "join", Infer), pos) | 1210 in |
1212 val e = (EApp (e, xmlOne), pos) | 1211 (EApp ((EApp ( |
1213 val e = (EApp (e, xml), pos) | 1212 (EVar (["Basis"], "join", Infer), pos), |
1214 val e = (EApp (e, (EVar (["Basis"], "css_subset", Infer), pos)), pos) | 1213 xmlOne), pos), |
1215 in | 1214 xml), pos) |
1216 (EApp (e, (EVar (["Basis"], "css_subset", Infer), pos)), pos) | |
1217 end) | 1215 end) |
1218 | xmlOne (xmlOne) | 1216 | xmlOne (xmlOne) |
1219 | 1217 |
1220 xmlOne : NOTAGS (EApp ((EVar (["Basis"], "cdata", Infer), s (NOTAGSleft, NOTAGSright)), | 1218 xmlOne : NOTAGS (EApp ((EVar (["Basis"], "cdata", Infer), s (NOTAGSleft, NOTAGSright)), |
1221 (EPrim (Prim.String NOTAGS), s (NOTAGSleft, NOTAGSright))), | 1219 (EPrim (Prim.String NOTAGS), s (NOTAGSleft, NOTAGSright))), |
1226 val cdata = | 1224 val cdata = |
1227 if #1 tag = "submit" orelse #1 tag = "dyn" then | 1225 if #1 tag = "submit" orelse #1 tag = "dyn" then |
1228 let | 1226 let |
1229 val e = (EVar (["Basis"], "cdata", DontInfer), pos) | 1227 val e = (EVar (["Basis"], "cdata", DontInfer), pos) |
1230 val e = (ECApp (e, (CWild (KWild, pos), pos)), pos) | 1228 val e = (ECApp (e, (CWild (KWild, pos), pos)), pos) |
1231 val e = (ECApp (e, (CRecord [], pos)), pos) | |
1232 in | 1229 in |
1233 (ECApp (e, (CRecord [], pos)), pos) | 1230 (ECApp (e, (CRecord [], pos)), pos) |
1234 end | 1231 end |
1235 else | 1232 else |
1236 (EVar (["Basis"], "cdata", Infer), pos) | 1233 (EVar (["Basis"], "cdata", Infer), pos) |
1267 (EApp (e, eexp), loc) | 1264 (EApp (e, eexp), loc) |
1268 end) | 1265 end) |
1269 | 1266 |
1270 tag : tagHead attrs (let | 1267 tag : tagHead attrs (let |
1271 val pos = s (tagHeadleft, attrsright) | 1268 val pos = s (tagHeadleft, attrsright) |
1272 val e = (EVar (["Basis"], "tag", Infer), pos) | 1269 in |
1273 val e = (EApp (e, (ERecord attrs, pos)), pos) | 1270 (#1 tagHead, |
1274 val e = (EApp (e, (EApp (#2 tagHead, (ERecord [], pos)), pos)), pos) | 1271 (EApp ((EApp ((EVar (["Basis"], "tag", Infer), pos), |
1275 val e = (EApp (e, (EVar (["Basis"], "css_subset", Infer), pos)), pos) | 1272 (ERecord attrs, pos)), pos), |
1276 val e = (EApp (e, (EVar (["Basis"], "css_subset", Infer), pos)), pos) | 1273 (EApp (#2 tagHead, |
1277 in | 1274 (ERecord [], pos)), pos)), |
1278 (#1 tagHead, e) | 1275 pos)) |
1279 end) | 1276 end) |
1280 | 1277 |
1281 tagHead: BEGIN_TAG (let | 1278 tagHead: BEGIN_TAG (let |
1282 val bt = tagIn BEGIN_TAG | 1279 val bt = tagIn BEGIN_TAG |
1283 val pos = s (BEGIN_TAGleft, BEGIN_TAGright) | 1280 val pos = s (BEGIN_TAGleft, BEGIN_TAGright) |