Make {} turn things into ords

Auditors: spicyj
This commit is contained in:
Emily Eisenberg
2013-07-09 21:14:04 -07:00
parent 29fde5d364
commit a95b93789a
2 changed files with 3 additions and 1 deletions

View File

@@ -88,6 +88,8 @@ var buildGroup = function(group, prev) {
return makeSpan("rlap", inner); return makeSpan("rlap", inner);
} else if (group.type === "punct") { } else if (group.type === "punct") {
return makeSpan("mpunct", textit(group.value)); return makeSpan("mpunct", textit(group.value));
} else if (group.type === "ordgroup") {
return makeSpan("mord", buildExpression(group.value));
} else { } else {
console.log("Unknown type:", group.type); console.log("Unknown type:", group.type);
} }

View File

@@ -36,7 +36,7 @@ group
: atom : atom
{$$ = $1;} {$$ = $1;}
| '{' ex '}' | '{' ex '}'
{$$ = $2;} {$$ = [{type: 'ordgroup', value: $2}];}
| func | func
{$$ = $1;} {$$ = $1;}
; ;