Remove usage of CHECK_NOTNULL
We want to switch to absl logging instead of glog. gtest and ceres are
going there, and we already have absl as a dependency. ABSL doesn't
have CHECK_NOTNULL, and we can move things over in an easier to review
fashion.
Change-Id: Ifd9a11ec34a2357cec43f88dba015db9c28ed2cf
Signed-off-by: Austin Schuh <austin.linux@gmail.com>
diff --git a/aos/flatbuffers.h b/aos/flatbuffers.h
index e5de120..f1ed626 100644
--- a/aos/flatbuffers.h
+++ b/aos/flatbuffers.h
@@ -87,10 +87,12 @@
}
uint8_t *data() final {
- return reinterpret_cast<uint8_t *>(CHECK_NOTNULL(data_));
+ CHECK(data_ != nullptr);
+ return reinterpret_cast<uint8_t *>(data_);
}
const uint8_t *data() const final {
- return reinterpret_cast<const uint8_t *>(CHECK_NOTNULL(data_));
+ CHECK(data_ != nullptr);
+ return reinterpret_cast<const uint8_t *>(data_);
}
size_t size() const final { return size_; }