mirror of
https://github.com/YosysHQ/yosys
synced 2025-06-06 14:13:23 +00:00
Changed frontend-api from FILE to std::istream
This commit is contained in:
parent
5dce303a2a
commit
19cff41eb4
22 changed files with 116 additions and 89 deletions
|
@ -41,10 +41,10 @@ namespace PASS_DFFLIBMAP
|
|||
|
||||
struct LibertyParser
|
||||
{
|
||||
FILE *f;
|
||||
std::istream &f;
|
||||
int line;
|
||||
LibertyAst *ast;
|
||||
LibertyParser(FILE *f) : f(f), line(1), ast(parse()) {}
|
||||
LibertyParser(std::istream &f) : f(f), line(1), ast(parse()) {}
|
||||
~LibertyParser() { if (ast) delete ast; }
|
||||
int lexer(std::string &str);
|
||||
LibertyAst *parse();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue