summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/netlist/plib/pparser.cpp
diff options
context:
space:
mode:
author couriersud <couriersud@gmx.org>2017-01-19 18:05:19 +0100
committer couriersud <couriersud@gmx.org>2017-01-20 22:29:23 +0100
commit4d15501a30d78eecc5011ebdd12a7568954129cb (patch)
treef3364bc26aae7719fb8fa3b153847188446844a7 /src/lib/netlist/plib/pparser.cpp
parent1ae3e29ea3fd90e5df31d52c5d3860fde7f3cbac (diff)
Netlist: code refactoring
Make streams provide binary access only. Use putf8_reader and putf8_writer to actually access streams. Replace some char * parameters with pstring where appropriate. Minor code refactoring and move functionality were it belongs. (nw)
Diffstat (limited to 'src/lib/netlist/plib/pparser.cpp')
-rw-r--r--src/lib/netlist/plib/pparser.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lib/netlist/plib/pparser.cpp b/src/lib/netlist/plib/pparser.cpp
index 35629aacdee..9d25adffcbe 100644
--- a/src/lib/netlist/plib/pparser.cpp
+++ b/src/lib/netlist/plib/pparser.cpp
@@ -15,7 +15,7 @@ namespace plib {
// A simple tokenizer
// ----------------------------------------------------------------------------------------
-ptokenizer::ptokenizer(pistream &strm)
+ptokenizer::ptokenizer(plib::putf8_reader &strm)
: m_strm(strm), m_lineno(0), m_cur_line(""), m_px(m_cur_line.begin()), m_unget(0), m_string('"')
{
}
@@ -483,7 +483,7 @@ pstring ppreprocessor::process_line(const pstring &line)
}
-postream & ppreprocessor::process_i(pistream &istrm, postream &ostrm)
+void ppreprocessor::process(putf8_reader &istrm, putf8_writer &ostrm)
{
pstring line;
while (istrm.readline(line))
@@ -491,7 +491,6 @@ postream & ppreprocessor::process_i(pistream &istrm, postream &ostrm)
line = process_line(line);
ostrm.writeline(line);
}
- return ostrm;
}
}