Add Travis build
1 file changed
tree: 7e7e6066ba0267dd989ef34f53975f11d1c13656
  1. src/
  2. tests/
  3. .gitignore
  4. .travis.yml
  5. Cargo.toml
  6. LICENSE-APACHE
  7. LICENSE-MIT
  8. README.md
README.md

Nom parser for Rust items

Parse Rust structs and enums without a Syntex dependency, intended for use with Macros 1.1.

[dependencies]
syn = "0.4"
extern crate syn;

let raw = "
    #[derive(Debug, Clone, Eq, PartialEq)]
    pub struct Item {
        pub ident: Ident,
        pub vis: Visibility,
        pub attrs: Vec<Attribute>,
        pub generics: Generics,
        pub body: Body,
    }
";

let ast = syn::parse_item(raw);

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this crate by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.