Single-character macros like active characters (#973)

* Single-character macros like active characters

* Rewrite README according to @kevinbarabash's comment
This commit is contained in:
Erik Demaine
2017-11-24 13:40:23 -05:00
committed by Kevin Barabash
parent b2698d35ec
commit ecad4de4ce
3 changed files with 8 additions and 2 deletions

View File

@@ -84,7 +84,7 @@ export default class MacroExpander implements MacroContextInterface {
// Consume all spaces after \macro (but not \\, \', etc.)
this.consumeSpaces();
}
if (!(isMacro && this.macros.hasOwnProperty(name))) {
if (!this.macros.hasOwnProperty(name)) {
// Fully expanded
this.pushToken(topToken);
return topToken;