diff --git a/include/verilated_cov.cpp b/include/verilated_cov.cpp index 7ed7e0031..901adada1 100644 --- a/include/verilated_cov.cpp +++ b/include/verilated_cov.cpp @@ -316,7 +316,7 @@ public: valps[2] = page_default.c_str(); // Keys -> strings - std::string keys[VerilatedCovConst::MAX_KEYS]; + std::array keys; for (int i = 0; i < VerilatedCovConst::MAX_KEYS; ++i) { if (ckeyps[i] && ckeyps[i][0]) keys[i] = ckeyps[i]; } diff --git a/src/V3DfgPeephole.h b/src/V3DfgPeephole.h index a20cadf6a..70cf8e044 100644 --- a/src/V3DfgPeephole.h +++ b/src/V3DfgPeephole.h @@ -123,9 +123,9 @@ struct V3DfgPeepholeContext final { const std::string m_label; // Label to apply to stats // Enable flags for each optimization - bool m_enabled[VDfgPeepholePattern::_ENUM_END]; + std::array m_enabled; // Count of applications for each optimization (for statistics) - VDouble0 m_count[VDfgPeepholePattern::_ENUM_END]; + std::array m_count; explicit V3DfgPeepholeContext(const std::string& label); ~V3DfgPeepholeContext(); diff --git a/src/V3File.cpp b/src/V3File.cpp index a197f6d6c..157e8d028 100644 --- a/src/V3File.cpp +++ b/src/V3File.cpp @@ -489,8 +489,8 @@ private: void startFilter(const string& command) { if (command == "") {} // Prevent Unused #ifdef INFILTER_PIPE - int fd_stdin[2]; - int fd_stdout[2]; + int fd_stdin[2]; // Can't use std::array + int fd_stdout[2]; // Can't use std::array constexpr int P_RD = 0; constexpr int P_WR = 1; diff --git a/src/V3Partition.cpp b/src/V3Partition.cpp index 41b41ba51..4eeb0d6a2 100644 --- a/src/V3Partition.cpp +++ b/src/V3Partition.cpp @@ -518,7 +518,7 @@ class MTaskEdge final : public V3GraphEdge, public MergeCandidate { // MEMBERS // This edge can be in 2 EdgeHeaps, one forward and one reverse. We allocate the heap nodes // directly within the edge as they are always required and this makes association cheap. - EdgeHeap::Node m_edgeHeapNode[GraphWay::NUM_WAYS]; + std::array m_edgeHeapNode; public: // CONSTRUCTORS @@ -1060,7 +1060,7 @@ class PartPropagateCpSelfTest final { private: // MEMBERS V3Graph m_graph; // A graph - LogicMTask* m_vx[50]; // All vertices within the graph + std::array m_vx; // All vertices within the graph // CONSTRUCTORS PartPropagateCpSelfTest() = default;