[llvm] [NFC][TableGen] Refactor DecoderEmitter.cpp (PR #135510)

Rahul Joshi via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 14 09:01:49 PDT 2025


================
@@ -982,11 +979,10 @@ void DecoderEmitter::emitTable(formatted_raw_ostream &OS, DecoderTable &Table,
 }
 
 void DecoderEmitter::emitInstrLenTable(formatted_raw_ostream &OS,
-                                       std::vector<unsigned> &InstrLen) const {
+                                       ArrayRef<unsigned> InstrLen) const {
   OS << "static const uint8_t InstrLenTable[] = {\n";
-  for (unsigned &Len : InstrLen) {
+  for (const unsigned &Len : InstrLen)
----------------
jurahul wrote:

Done.

https://github.com/llvm/llvm-project/pull/135510


More information about the llvm-commits mailing list