MCPcopy Create free account
hub / github.com/cel-expr/cel-cpp / Borrow

Method Borrow

common/memory.h:1289–1294  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1287struct Borrowable {
1288 protected:
1289 Borrowed<const T> Borrow() const noexcept {
1290 static_assert(std::is_base_of_v<Data, T>, "T must be derived from Data");
1291 const T* const that = static_cast<const T*>(this);
1292 return Borrowed<const T>(Borrower(static_cast<const Data*>(that)->owner_),
1293 that);
1294 }
1295
1296 Borrowed<T> Borrow() noexcept {
1297 static_assert(std::is_base_of_v<Data, T>, "T must be derived from Data");

Callers

nothing calls this directly

Calls 1

BorrowerClass · 0.85

Tested by

no test coverage detected