summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/netlist/plib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/netlist/plib')
-rw-r--r--src/lib/netlist/plib/pexception.h4
-rw-r--r--src/lib/netlist/plib/ptokenizer.h46
-rw-r--r--src/lib/netlist/plib/ptypes.h24
3 files changed, 55 insertions, 19 deletions
diff --git a/src/lib/netlist/plib/pexception.h b/src/lib/netlist/plib/pexception.h
index 2023fb91c38..709f8810b83 100644
--- a/src/lib/netlist/plib/pexception.h
+++ b/src/lib/netlist/plib/pexception.h
@@ -40,10 +40,10 @@ namespace plib {
explicit pexception(const pstring &text);
const pstring &text() const noexcept { return m_text; }
- const char* what() const noexcept override { return putf8string(m_text).c_str(); }
+ const char* what() const noexcept override { return m_text.c_str(); }
private:
- pstring m_text;
+ putf8string m_text;
};
class file_e : public plib::pexception
diff --git a/src/lib/netlist/plib/ptokenizer.h b/src/lib/netlist/plib/ptokenizer.h
index 717d3fcd550..9a194a542d5 100644
--- a/src/lib/netlist/plib/ptokenizer.h
+++ b/src/lib/netlist/plib/ptokenizer.h
@@ -19,22 +19,7 @@
namespace plib {
- class ptokenizer
- {
- public:
- explicit ptokenizer() // NOLINT(misc-forwarding-reference-overload, bugprone-forwarding-reference-overload)
- : m_strm(nullptr)
- , m_unget(0)
- , m_string('"')
- , m_support_line_markers(true) // FIXME
- , m_token_queue(nullptr)
- {
- clear();
- }
-
- PCOPYASSIGNMOVE(ptokenizer, delete)
-
- virtual ~ptokenizer() = default;
+ namespace detail {
PENUM(token_type,
IDENTIFIER,
@@ -109,7 +94,34 @@ namespace plib {
pstring m_token;
};
- using token_store = std::vector<token_t>;
+ class token_store : public std::vector<token_t>
+ {
+ using std::vector<token_t>::vector;
+ };
+
+ } // namespace detail
+
+ class ptokenizer
+ {
+ public:
+ explicit ptokenizer() // NOLINT(misc-forwarding-reference-overload, bugprone-forwarding-reference-overload)
+ : m_strm(nullptr)
+ , m_unget(0)
+ , m_string('"')
+ , m_support_line_markers(true) // FIXME
+ , m_token_queue(nullptr)
+ {
+ clear();
+ }
+
+ PCOPYASSIGNMOVE(ptokenizer, delete)
+
+ virtual ~ptokenizer() = default;
+
+ using token_type = detail::token_type;
+ using token_id_t = detail::token_id_t;
+ using token_t = detail::token_t;
+ using token_store = detail::token_store;
// tokenizer stuff follows ...
diff --git a/src/lib/netlist/plib/ptypes.h b/src/lib/netlist/plib/ptypes.h
index 5c5cb37695a..544b8ab0eff 100644
--- a/src/lib/netlist/plib/ptypes.h
+++ b/src/lib/netlist/plib/ptypes.h
@@ -39,6 +39,30 @@
#undef EMSCRIPTEN
#endif
+// -----------------------------------------------------------------------------
+// forward definitions
+// -----------------------------------------------------------------------------
+
+namespace plib
+{
+ template <typename BASEARENA, std::size_t MINALIGN>
+ class mempool_arena;
+
+ struct aligned_arena;
+ class dynlib_base;
+
+ template<bool debug_enabled>
+ class plog_base;
+
+ struct plog_level;
+
+ namespace detail
+ {
+ class token_store;
+ } // namespace detail
+
+} // namespace plib
+
namespace plib
{
//============================================================