Internals: Use and enforce class final for ~5% performance boost.

This commit is contained in:
Wilson Snyder
2020-11-18 21:32:16 -05:00
parent c0888c1b0f
commit b6ded59c2b
224 changed files with 976 additions and 949 deletions
+4 -4
View File
@@ -43,7 +43,7 @@
//*************************************************************************
class VDefine {
class VDefine final {
// Define class. One for each define.
// string m_name; // Name of the define (list is keyed by this)
FileLine* m_fileline; // Where it was declared
@@ -64,7 +64,7 @@ public:
//*************************************************************************
class VDefineRef {
class VDefineRef final {
// One for each pending define substitution
string m_name; // Define last name being defined
string m_params; // Define parameter list for next expansion
@@ -89,7 +89,7 @@ public:
//*************************************************************************
/// Data for parsing on/off
class VPreIfEntry {
class VPreIfEntry final {
// One for each pending ifdef/ifndef
bool m_on; // Current parse for this ifdef level is "on"
bool m_everOn; // Some if term in elsif tree has been on
@@ -105,7 +105,7 @@ public:
//*************************************************************************
// Data for a preprocessor instantiation.
class V3PreProcImp : public V3PreProc {
class V3PreProcImp final : public V3PreProc {
public:
// TYPES
typedef std::map<const string, VDefine> DefinesMap;