mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-20 16:17:38 +00:00
stringref'ize readRecord and properly capitalize it. Add a compatibility method to easy
the transition. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172940 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -506,9 +506,20 @@ public:
|
||||
/// skipRecord - Read the current record and discard it.
|
||||
void skipRecord(unsigned AbbrevID);
|
||||
|
||||
unsigned readRecord(unsigned AbbrevID, SmallVectorImpl<uint64_t> &Vals,
|
||||
StringRef *Blob = 0);
|
||||
|
||||
unsigned ReadRecord(unsigned AbbrevID, SmallVectorImpl<uint64_t> &Vals,
|
||||
const char **BlobStart = 0, unsigned *BlobLen = 0);
|
||||
|
||||
const char **BlobStart = 0, unsigned *BlobLen = 0) {
|
||||
if (!BlobStart)
|
||||
return readRecord(AbbrevID, Vals);
|
||||
StringRef S;
|
||||
unsigned X = readRecord(AbbrevID, Vals, &S);
|
||||
*BlobStart = S.data();
|
||||
*BlobLen = S.size();
|
||||
return X;
|
||||
}
|
||||
|
||||
unsigned ReadRecord(unsigned AbbrevID, SmallVectorImpl<uint64_t> &Vals,
|
||||
const char *&BlobStart, unsigned &BlobLen) {
|
||||
return ReadRecord(AbbrevID, Vals, &BlobStart, &BlobLen);
|
||||
|
||||
Reference in New Issue
Block a user