File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -758,6 +758,8 @@ FlatCOptions FlatCompiler::ParseFromCommandLineArguments(int argc,
758758 }
759759 }
760760
761+ ValidateOptions (options);
762+
761763 return options;
762764}
763765
@@ -766,9 +768,8 @@ void FlatCompiler::ValidateOptions(const FlatCOptions &options) {
766768
767769 if (!options.filenames .size ()) Error (" missing input files" , false , true );
768770
769- if (opts.proto_mode ) {
770- if (options.any_generator )
771- Error (" cannot generate code directly from .proto files" , true );
771+ if (opts.proto_mode && options.any_generator ) {
772+ Warn (" cannot generate code directly from .proto files" , true );
772773 } else if (!options.any_generator && options.conform_to_schema .empty () &&
773774 options.annotate_schema .empty ()) {
774775 Error (" no options: specify at least one generator." , true );
You can’t perform that action at this time.
0 commit comments