mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-04 12:43:24 +00:00
Nullable java (#4455)
* add _Nullable Support for C++ interface * generate @Nullable for Java generated code
This commit is contained in:
committed by
Wouter van Oortmerssen
parent
a1b5f565d9
commit
01bac38c84
@@ -127,7 +127,7 @@ class CppGenerator : public BaseGenerator {
|
||||
code_ += "#define " + include_guard;
|
||||
code_ += "";
|
||||
|
||||
if (parser_.opts.clang_nullable) {
|
||||
if (parser_.opts.gen_nullable) {
|
||||
code_ += "#pragma clang system_header\n\n";
|
||||
}
|
||||
|
||||
@@ -433,7 +433,7 @@ class CppGenerator : public BaseGenerator {
|
||||
}
|
||||
|
||||
std::string NullableExtension() {
|
||||
return parser_.opts.clang_nullable ? " _Nullable " : "";
|
||||
return parser_.opts.gen_nullable ? " _Nullable " : "";
|
||||
}
|
||||
|
||||
static std::string NativeName(const std::string &name, const StructDef *sd, const IDLOptions & opts) {
|
||||
|
||||
Reference in New Issue
Block a user