llvm.org GIT mirror llvm / fade2f7
[TableGen] Change a couple methods to return an ArrayRef instead of a const std::vector reference. NFC git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241430 91177308-0d34-0410-b5e6-96231b3b80d8 Craig Topper 5 years ago
4 changed file(s) with 6 addition(s) and 6 deletion(s). Raw diff Collapse all Expand all
12211221 /// get the corresponding DefInit.
12221222 DefInit *getDefInit();
12231223
1224 const std::vector &getTemplateArgs() const {
1224 ArrayRef getTemplateArgs() const {
12251225 return TemplateArgs;
12261226 }
1227 const std::vector &getValues() const { return Values; }
1228 const std::vector &getSuperClasses() const { return SuperClasses; }
1227 ArrayRef getValues() const { return Values; }
1228 ArrayRef getSuperClasses() const { return SuperClasses; }
12291229 ArrayRef getSuperClassRanges() const { return SuperClassRanges; }
12301230
12311231 bool isTemplateArg(Init *Name) const {
16471647 }
16481648
16491649 OS << " {";
1650 const std::vector &SC = R.getSuperClasses();
1650 ArrayRef SC = R.getSuperClasses();
16511651 if (!SC.empty()) {
16521652 OS << "\t//";
16531653 for (const Record *Super : SC)
301301 return &I->second;
302302
303303 // This is the first time we see Set. Find a suitable expander.
304 const std::vector &SC = Set->getSuperClasses();
304 ArrayRef SC = Set->getSuperClasses();
305305 for (unsigned i = 0, e = SC.size(); i != e; ++i) {
306306 // Skip unnamed superclasses.
307307 if (!dyn_cast(SC[i]->getNameInit()))
183183
184184 // Since everything went well, we can now set the "superclass" list for the
185185 // current record.
186 const std::vector &SCs = SC->getSuperClasses();
186 ArrayRef SCs = SC->getSuperClasses();
187187 ArrayRef SCRanges = SC->getSuperClassRanges();
188188 for (unsigned i = 0, e = SCs.size(); i != e; ++i) {
189189 if (CurRec->isSubClassOf(SCs[i]))