verilog_filelist_parser/lib.rs
1//! # Verilog Filelist Parser
2//!
3//! A library to parse a Verilog Filelist and return
4//! a list of files, include directories and defines.
5//!
6//! Environment variables represented with paranthesis or
7//! curly braces (i.e. `$()` or `${}`) will be automatically
8//! substituted.
9//!
10//! # Example
11//! ```
12//! use verilog_filelist_parser;
13//! let filelist = verilog_filelist_parser::parse_file("testcase/files.f")
14//! .expect("Cannot read filelist");
15//! for file in filelist.files {
16//! println!("{:?}", file);
17//! }
18//! for incdir in filelist.incdirs {
19//! println!("{:?}", incdir);
20//! }
21//! for (d, t) in filelist.defines {
22//! match t {
23//! None => println!("{:?}", d),
24//! Some(te) => println!("{:?}={:?}", d, te),
25//! };
26//! }
27//! ```
28
29mod file_parser;
30mod line_parser;
31
32pub use file_parser::parse_file;
33pub use file_parser::Filelist;