Browse Source

Docs fix (Issue #560)

tags/gm/2021-09-23T00Z/github.com--lark-parser-lark/0.8.6
Erez Sh 5 years ago
parent
commit
227f5de927
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      docs/grammar.md

+ 2
- 2
docs/grammar.md View File

@@ -233,7 +233,7 @@ When importing rules, all their dependencies will be imported into a namespace,
%import <module>.<rule>
%import <module>.<TERMINAL> -> <NEWTERMINAL>
%import <module>.<rule> -> <newrule>
%import <module> (<TERM1> <TERM2> <rule1> <rule2>)
%import <module> (<TERM1>, <TERM2>, <rule1>, <rule2>)
```

If the module path is absolute, Lark will attempt to load it from the built-in directory (currently, only `common.lark` is available).
@@ -246,7 +246,7 @@ The rule or terminal can be imported under an other name with the `->` syntax.
```perl
%import common.NUMBER

%import .terminals_file (A B C)
%import .terminals_file (A, B, C)

%import .rules_file.rulea -> ruleb
```


Loading…
Cancel
Save