swift
5dbc8c25 - [cxx-interop] Support ownership annotations on FRT constructors

Commit
73 days ago
[cxx-interop] Support ownership annotations on FRT constructors We were previously marking synthesized FRT initializers as "returns_retained" unconditionally (for non-immortal types), which can cause memory errors and also suppresses diagnostics about the lack of such annotations. This patch fixes that behavior, and also adjusts the source locations of the synthesized C++ factory method to point to the actual constructor decl when its location is available, so that the diagnostics make sense when warning about the lack of annotations. rdar://163127315
Author
Committer
Parents
Loading