| 2118 | } |
| 2119 | |
| 2120 | BorrowingLiteral::BorrowingLiteral(const char* src_buf_ptr, const Shape& shape) |
| 2121 | : LiteralBase(), shape_(absl::make_unique<Shape>(shape)) { |
| 2122 | CHECK(shape_->IsArray()); |
| 2123 | CHECK(LayoutUtil::HasLayout(*shape_)); |
| 2124 | |
| 2125 | root_piece_ = Piece(); |
| 2126 | root_piece_.set_buffer(const_cast<char*>(src_buf_ptr)); |
| 2127 | root_piece_.set_subshape(shape_.get()); |
| 2128 | } |
| 2129 | |
| 2130 | BorrowingLiteral::BorrowingLiteral(absl::Span<const char* const> src_buf_ptrs, |
| 2131 | const Shape& shape) |
nothing calls this directly
no test coverage detected