mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Add error message for incorrect member lookup.
This commit is contained in:
parent
a6956ed0e4
commit
53823d0f27
@ -8,6 +8,7 @@
|
||||
|
||||
#include "impeller/archivist/archive_database.h"
|
||||
#include "impeller/archivist/archive_statement.h"
|
||||
#include "impeller/base/validation.h"
|
||||
|
||||
namespace impeller {
|
||||
|
||||
@ -39,6 +40,9 @@ std::optional<size_t> ArchiveClassRegistration::FindColumnIndex(
|
||||
const std::string& member) const {
|
||||
auto found = column_map_.find(member);
|
||||
if (found == column_map_.end()) {
|
||||
VALIDATION_LOG << "No member named '" << member << "' in class '"
|
||||
<< definition_.table_name
|
||||
<< "'. Did you forget to register it?";
|
||||
return std::nullopt;
|
||||
}
|
||||
return found->second;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user