forked from OSchip/llvm-project
Add const version of OwningBinary::getBinary
llvm-svn: 220231
This commit is contained in:
parent
798ff92c3c
commit
3c6915fa40
|
@ -140,6 +140,7 @@ public:
|
|||
OwningBinary<T> &operator=(OwningBinary<T> &&Other);
|
||||
|
||||
std::unique_ptr<T> &getBinary();
|
||||
const std::unique_ptr<T> &getBinary() const;
|
||||
std::unique_ptr<MemoryBuffer> &getBuffer();
|
||||
};
|
||||
|
||||
|
@ -165,6 +166,11 @@ template <typename T> std::unique_ptr<T> &OwningBinary<T>::getBinary() {
|
|||
return Bin;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
const std::unique_ptr<T> &OwningBinary<T>::getBinary() const {
|
||||
return Bin;
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
std::unique_ptr<MemoryBuffer> &OwningBinary<T>::getBuffer() {
|
||||
return Buf;
|
||||
|
|
Loading…
Reference in New Issue