* Determine whether a command is expandable.
(name: string)
| 459 | * Determine whether a command is expandable. |
| 460 | */ |
| 461 | isExpandable(name: string): boolean { |
| 462 | const macro = this.macros.get(name); |
| 463 | return macro != null ? typeof macro === "string" |
| 464 | || typeof macro === "function" || !macro.unexpandable |
| 465 | : functions.hasOwnProperty(name) && !functions[name].primitive; |
| 466 | } |
| 467 | } |