Преглед изворни кода

Added documentation

tags/gm/2021-09-23T00Z/github.com--lark-parser-lark/0.11.2
Erez Sh пре 3 година
родитељ
комит
bcf9957575
1 измењених фајлова са 13 додато и 0 уклоњено
  1. +13
    -0
      docs/grammar.md

+ 13
- 0
docs/grammar.md Прегледај датотеку

@@ -289,3 +289,16 @@ Note that `%ignore` directives cannot be imported. Imported rules will abide by

Declare a terminal without defining it. Useful for plugins.

### %override

Override a rule, affecting all the rules that refer to it.

Useful for implementing an inheritance pattern when importing grammars.

**Example:**
```perl
%import my_grammar (start, number, NUMBER)

// Add hex support to my_grammar
%override number: NUMBER | /0x\w+/
```

Loading…
Откажи
Сачувај