File: duplicate_rule.rs

package info (click to toggle)
rust-peg 0.8.5-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental, forky, sid, trixie
  • size: 756 kB
  • sloc: makefile: 20; sh: 12
file content (9 lines) | stat: -rw-r--r-- 219 bytes parent folder | download
1
2
3
4
5
6
7
8
9
extern crate peg;

peg::parser!(grammar foo() for str { //~ ERROR  the name `__parse_foo` is defined multiple times [E0428]
    rule foo() = "foo"

    rule foo() = "xyz" //~ ERROR duplicate rule `foo`
});

fn main() {}