Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Parse a comma-separated list of numbers surrounded by brackets into a `Vec<u32>`

```rust
peg::parser!{
grammar list_parser() for str {
grammar list_parser() for &str {
rule number() -> u32
= n:$(['0'..='9']+) {? n.parse().or(Err("u32")) }

Expand Down
2 changes: 1 addition & 1 deletion benches/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ extern crate test;

use test::Bencher;

peg::parser!(grammar parser() for str {
peg::parser!(grammar parser() for &str {
crate rule expr() = eq()

#[cache]
Expand Down
2 changes: 1 addition & 1 deletion benches/json.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ extern crate test;

use test::Bencher;

peg::parser!(grammar parser() for str {
peg::parser!(grammar parser() for &str {
// JSON grammar (RFC 4627). Note that this only checks for valid JSON and does not build a syntax
// tree.

Expand Down
Loading