Skip to content

Commit

Permalink
Can now track the source file and line of all constructs.
Browse files Browse the repository at this point in the history
 On branch master
 Your branch is up-to-date with 'origin/master'.

 Changes to be committed:
	modified:   scratchpad.md
	modified:   src/main.c
	modified:   src/verilog_ast.c
	modified:   src/verilog_parser_wrapper.c
	modified:   src/verilog_preprocessor.c
	modified:   src/verilog_preprocessor.h
	modified:   src/verilog_scanner.l
  • Loading branch information
ben-marshall committed Jul 30, 2016
1 parent 0830e8a commit b9120b5
Show file tree
Hide file tree
Showing 7 changed files with 173 additions and 97 deletions.
2 changes: 1 addition & 1 deletion scratchpad.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ A file of todo-lists, notes, and other useful stuff.
### Features

- [ ] `ast_expression_tostring()` function
- [ ] Track source *file* of a construct, as well as line number.
- [X] Track source *file* of a construct, as well as line number.
- [ ] Track macro evaluations.
- [ ] Freeing of individual memory structures, rather than all at once.

Expand Down
2 changes: 2 additions & 0 deletions src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ int main(int argc, char ** argv)

// Load the file.
FILE * fh = fopen(argv[F], "r");

verilog_preprocessor_set_file(yy_preproc, argv[F]);

// Parse the file and store the result.
int result = verilog_parse_file(fh);
Expand Down
Loading

0 comments on commit b9120b5

Please sign in to comment.