diff options
author | 2020-05-17 19:35:11 +0200 | |
---|---|---|
committer | 2020-05-17 19:52:24 +0200 | |
commit | a94de94c734dcba5648f223c9f0c5f07d4f0ce96 (patch) | |
tree | bafc20928d56dc7e00f02aef2d544b0701b71f1a /src/lib/netlist/nl_parser.cpp | |
parent | 22fb995337f7f1d666f411c15873c7fe858e022f (diff) |
netlist: improve typesafety for source locations. (nw)
During object creation netlist tracks the source files which provide
object creation. This is later used e.g. by nltool to create
documentation from source.
Diffstat (limited to 'src/lib/netlist/nl_parser.cpp')
-rw-r--r-- | src/lib/netlist/nl_parser.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/netlist/nl_parser.cpp b/src/lib/netlist/nl_parser.cpp index 28ef731820b..84b09bde1e0 100644 --- a/src/lib/netlist/nl_parser.cpp +++ b/src/lib/netlist/nl_parser.cpp @@ -132,8 +132,8 @@ void parser_t::parse_netlist(const pstring &nlname) else if (token.is(m_tok_LOCAL_LIB_ENTRY)) { require_token(m_tok_paren_left); - // FIXME: Need to pass in parameter definition - m_setup.register_lib_entry(get_identifier(), "", "parser: " + nlname); + // FIXME: Need to pass in parameter definition FIXME: get line number right + m_setup.register_lib_entry(get_identifier(), "", plib::source_location("parser: " + nlname, 1)); require_token(m_tok_paren_right); } else if (token.is(m_tok_NETLIST_END)) @@ -199,7 +199,8 @@ void parser_t::net_truthtable_start(const pstring &nlname) require_token(token, m_tok_TRUTHTABLE_END); require_token(m_tok_paren_left); require_token(m_tok_paren_right); - m_setup.truthtable_create(desc, nlname); + // FIXME: proper location + m_setup.truthtable_create(desc, plib::source_location(nlname, 1)); return; } } |