[PATCH] D26219: Bitcode: Change reader interface to take memory buffers.
Mehdi AMINI via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 1 16:25:40 PDT 2016
mehdi_amini added inline comments.
================
Comment at: llvm/include/llvm/Bitcode/BitstreamReader.h:63
public:
- BitstreamReader() : IgnoreBlockInfoNames(true) {
- }
-
- BitstreamReader(const unsigned char *Start, const unsigned char *End)
- : IgnoreBlockInfoNames(true) {
- init(Start, End);
- }
-
- BitstreamReader(std::unique_ptr<MemoryObject> BitcodeBytes)
- : BitcodeBytes(std::move(BitcodeBytes)), IgnoreBlockInfoNames(true) {}
-
- void init(const unsigned char *Start, const unsigned char *End) {
- assert(((End-Start) & 3) == 0 &&"Bitcode stream not a multiple of 4 bytes");
- BitcodeBytes.reset(getNonStreamedMemoryObject(Start, End));
- }
-
- MemoryObject &getBitcodeBytes() { return *BitcodeBytes; }
+ BitstreamReader() {}
+ BitstreamReader(ArrayRef<uint8_t> BitcodeBytes)
----------------
The `= default()` was supposed to be here (commented while you updated the diff)
https://reviews.llvm.org/D26219
More information about the llvm-commits
mailing list