Merge pull request #85647 from eeckstein/fix-embedded-cpp-classes

embedded: don't try to specialize vtables of C++ imported reference-counted classes
This commit is contained in:
eeckstein
2025-12-01 09:35:19 +01:00
committed by GitHub
5 changed files with 19 additions and 0 deletions

View File

@@ -346,6 +346,7 @@ struct BridgedDeclObj {
BRIDGED_INLINE bool Struct_hasUnreferenceableStorage() const;
SWIFT_IMPORT_UNSAFE BRIDGED_INLINE BridgedASTType Class_getSuperclass() const;
SWIFT_IMPORT_UNSAFE BRIDGED_INLINE BridgedDeclObj Class_getDestructor() const;
BRIDGED_INLINE bool Class_isForeign() const;
BRIDGED_INLINE bool ProtocolDecl_requiresClass() const;
BRIDGED_INLINE bool AbstractFunction_isOverridden() const;
BRIDGED_INLINE bool Destructor_isIsolated() const;

View File

@@ -256,6 +256,10 @@ BridgedDeclObj BridgedDeclObj::Class_getDestructor() const {
return {getAs<swift::ClassDecl>()->getDestructor()};
}
bool BridgedDeclObj::Class_isForeign() const {
return getAs<swift::ClassDecl>()->isForeign();
}
bool BridgedDeclObj::ProtocolDecl_requiresClass() const {
return getAs<swift::ProtocolDecl>()->requiresClass();
}