Use AIDL_* errors over libbase logging.
This:
- gives us line numbers in source AIDL files reflecting errors
- makes it possible aidl_parser_fuzzer can detect when we return an
error but don't provide any output logging
Bug: N/A
Test: aidl_unittest
Change-Id: I0479fd8d87547c1f0b1be754f9b8f6865db3cbef
diff --git a/parser.h b/parser.h
index 23da269..0d39342 100644
--- a/parser.h
+++ b/parser.h
@@ -19,8 +19,8 @@
#include "aidl_language.h"
#include "aidl_typenames.h"
#include "io_delegate.h"
+#include "logging.h"
#include "options.h"
-#include <android-base/logging.h>
#include <memory>
#include <string>
@@ -88,7 +88,7 @@
}
const AidlDocument& ParsedDocument() const {
- CHECK(!HasError());
+ AIDL_FATAL_IF(HasError(), FileName());
return *document_;
}