diff --git a/src/tools/qtgrpcgen/qgrpcgenerator.cpp b/src/tools/qtgrpcgen/qgrpcgenerator.cpp index ace0b684..bf90e525 100644 --- a/src/tools/qtgrpcgen/qgrpcgenerator.cpp +++ b/src/tools/qtgrpcgen/qgrpcgenerator.cpp @@ -30,13 +30,9 @@ QGrpcGenerator::~QGrpcGenerator() = default; bool QGrpcGenerator::Generate(const FileDescriptor *file, [[maybe_unused]] const std::string ¶meter, GeneratorContext *generatorContext, - std::string *error) const + [[maybe_unused]] std::string *error) const { assert(file != nullptr && generatorContext != nullptr); - if (file->syntax() != FileDescriptor::SYNTAX_PROTO3) { - *error = "Invalid proto used. qtgrpcgen only supports 'proto3' syntax"; - return false; - } return GenerateClientServices(file, generatorContext); } diff --git a/src/tools/qtprotobufgen/qprotobufgenerator.cpp b/src/tools/qtprotobufgen/qprotobufgenerator.cpp index 9c1e168c..b136fe33 100644 --- a/src/tools/qtprotobufgen/qprotobufgenerator.cpp +++ b/src/tools/qtprotobufgen/qprotobufgenerator.cpp @@ -36,16 +36,11 @@ QProtobufGenerator::~QProtobufGenerator() = default; bool QProtobufGenerator::Generate(const FileDescriptor *file, [[maybe_unused]] const std::string ¶meter, GeneratorContext *generatorContext, - std::string *error) const + [[maybe_unused]] std::string *error) const { assert(file != nullptr); assert(generatorContext != nullptr); - if (file->syntax() != FileDescriptor::SYNTAX_PROTO3) { - *error = "Invalid proto used. qtprotobufgen only supports 'proto3' syntax"; - return false; - } - return GenerateMessages(file, generatorContext); }