dansimon / peruse Goto Github PK
View Code? Open in Web Editor NEWA parser-combinator library for Rust
License: MIT License
A parser-combinator library for Rust
License: MIT License
Hey, I'm getting this error when trying to combine my own parser using any of the macros, do you have any ideas on maybe I'm doing incorrectly?
#[phase(plugin)]
extern crate peruse;
extern crate peruse;
use self::peruse::parsers::literal;
fn mm() {
let dddd = or!(literal(A), literal(B));
}
The full error I get from trying to compile this:
badamson@406c8f2a3866 ~/D/r/myproject-rs> cargo build --verbose
Fresh peruse v0.1.0 (https://github.com/DanSimon/peruse.git#5915d6fa)
Compiling myproject-rs v0.0.1 (file:///Users/badamson/Documents/rust/myproject-rs)
Running `rustc /Users/badamson/Documents/rust/myproject-rs/src/main.rs --crate-name myproject-rs --crate-type bin -g --out-dir /Users/badamson/Documents/rust/myproject-rs/target --dep-info /Users/badamson/Documents/rust/myproject-rs/target/.fingerprint/myproject-rs-030fbdb89d7c4fb3/dep-bin-myproject-rs -L /Users/badamson/Documents/rust/myproject-rs/target -L /Users/badamson/Documents/rust/myproject-rs/target/deps --extern peruse=/Users/badamson/Documents/rust/myproject-rs/target/deps/libperuse-1cb3ff65831a86b2.rlib`
<peruse macros>:3:5: 3:13 error: `OrParser` does not name a structure
<peruse macros>:3 OrParser{
^~~~~~~~
<peruse macros>:1:1: 18:2 note: in expansion of or!
/Users/badamson/Documents/rust/myproject-rs/src/lexer/lexer.rs:43:13: 43:41 note: expansion site
error: aborting due to previous error
Could not compile `myproject-rs`.
Caused by:
Process didn't exit successfully: `rustc /Users/badamson/Documents/rust/myproject-rs/src/main.rs --crate-name myproject-rs --crate-type bin -g --out-dir /Users/badamson/Documents/rust/myproject-rs/target --dep-info /Users/badamson/Documents/rust/myproject-rs/target/.fingerprint/myproject-rs-030fbdb89d7c4fb3/dep-bin-myproject-rs -L /Users/badamson/Documents/rust/myproject-rs/target -L /Users/badamson/Documents/rust/myproject-rs/target/deps --extern peruse=/Users/badamson/Documents/rust/myproject-rs/target/deps/libperuse-1cb3ff65831a86b2.rlib` (status=101)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.