This repository was archived by the owner on Nov 21, 2025. It is now read-only.
Commit ee9900a
committed
Properly parse nested ternary expressions
The previous implementation of the template grammar for ternary
expressions would not match nested ternary expressions. In this commit
we update the matcher to use the TypeScript TM grammar's implementation
to do this correctly. Screenshots attached to the PR for this commit
demonstrate the change in a "real" template.
Closes #9571 parent d291a15 commit ee9900a
File tree
4 files changed
+41
-37
lines changed- syntaxes
- src
- test/data
4 files changed
+41
-37
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
563 | 563 | | |
564 | 564 | | |
565 | 565 | | |
566 | | - | |
567 | | - | |
568 | | - | |
569 | | - | |
570 | | - | |
571 | | - | |
572 | | - | |
573 | | - | |
574 | | - | |
575 | | - | |
576 | | - | |
577 | | - | |
578 | | - | |
| 566 | + | |
579 | 567 | | |
580 | | - | |
| 568 | + | |
581 | 569 | | |
582 | 570 | | |
583 | 571 | | |
584 | | - | |
| 572 | + | |
585 | 573 | | |
586 | | - | |
| 574 | + | |
587 | 575 | | |
588 | 576 | | |
589 | 577 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
594 | 594 | | |
595 | 595 | | |
596 | 596 | | |
597 | | - | |
598 | | - | |
599 | | - | |
600 | | - | |
601 | | - | |
602 | | - | |
603 | | - | |
604 | | - | |
605 | | - | |
606 | | - | |
607 | | - | |
608 | | - | |
609 | | - | |
610 | | - | |
| 597 | + | |
611 | 598 | | |
612 | | - | |
| 599 | + | |
613 | 600 | | |
614 | 601 | | |
615 | 602 | | |
616 | | - | |
| 603 | + | |
617 | 604 | | |
618 | | - | |
| 605 | + | |
619 | 606 | | |
620 | 607 | | |
621 | 608 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| 73 | + | |
73 | 74 | | |
74 | 75 | | |
75 | 76 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
756 | 756 | | |
757 | 757 | | |
758 | 758 | | |
759 | | - | |
760 | | - | |
| 759 | + | |
761 | 760 | | |
762 | 761 | | |
763 | 762 | | |
| |||
794 | 793 | | |
795 | 794 | | |
796 | 795 | | |
797 | | - | |
798 | | - | |
| 796 | + | |
799 | 797 | | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
800 | 828 | | |
801 | 829 | | |
802 | 830 | | |
| |||
0 commit comments