Commit 8c796a1
committed
Define a rule in context before parsing its prelude
Prior to this commit and 62c87e1, a rule, declaration, function, was defined in
`context` only when parsing its associated value. It is now also defined when
parsing the prelude of a rule and the name of a function.
The intention was to consider them as execution contexts (scopes) rather than
grammars (nodes) but in other programming languages, the arguments and value of
a function are actually defined in the same scope.
Comparing CSS to other programming languages may not hold any further. In CSS,
most expressions are defined by the language rather than the user. The name of
the structure defines its grammar but it is also part of the production, which
implicitly accepts aliases and mappings.1 parent bd67248 commit 8c796a1
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
624 | 624 | | |
625 | 625 | | |
626 | 626 | | |
627 | | - | |
| 627 | + | |
628 | 628 | | |
629 | 629 | | |
630 | 630 | | |
| |||
651 | 651 | | |
652 | 652 | | |
653 | 653 | | |
654 | | - | |
| 654 | + | |
655 | 655 | | |
656 | 656 | | |
657 | 657 | | |
| |||
665 | 665 | | |
666 | 666 | | |
667 | 667 | | |
668 | | - | |
| 668 | + | |
669 | 669 | | |
670 | 670 | | |
671 | 671 | | |
| |||
0 commit comments