[Python] Avoid include own type (#8625)

This prevents the include of the type defined in the pyi,
otherwise this leads to error message like this:
error: Name XYZ already defined (possibly by an import)  [no-redef]
This commit is contained in:
Felix 2025-07-15 20:20:09 +02:00 committed by GitHub
parent 4c9079e31b
commit c7b9dc83f5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 45 additions and 16 deletions

View file

@ -85,7 +85,12 @@ struct Imports {
const python::Import &Import(const std::string &module,
const std::string &name);
const python::Import &Export(const std::string &module);
const python::Import &Export(const std::string &module,
const std::string &name);
std::vector<python::Import> imports;
std::vector<python::Import> exports;
};
} // namespace python
} // namespace flatbuffers