[cfe-dev] Adding Support for APINotes
Chris Lattner via cfe-dev
cfe-dev at lists.llvm.org
Tue Oct 6 22:12:34 PDT 2020
> On Oct 6, 2020, at 10:10 PM, Chris Lattner <clattner at nondot.org> wrote:
>
>> (And, as a sidenote, it also seems unclear to me that Swift really needed APINotes to be put into Clang (even Swift's fork of Clang) vs building the similar functionality into the Swift consumer of the Clang AST. Possibly this was an arbitrary choice made early on. Or maybe there's good reasons why it wouldn't work to do that way which aren't obvious at a quick glance. Bu, I suspect there is no appetite for making such a large design change now, even if it could've been better, so that's not really a useful discussion to have.)
>
> I think that is a fairly reasonable characterization from what I know, but I would go a bit further - we don’t always make “perfection” be the barrier to landing something in mainline; we make “good enough” be the threshold. Is the current implementation of APINotes a useful baseline that can be extended in the future?
Just to be pointed about this, I’ll give an example: modules. Modules was built specifically to enable Swift, but was explained as a way of accelerating C/ObjC build times. Clang supported C++ at the time, but modules did not. I think that modules existing in clang helped catalyze and provide a basis for C++ modules that has benefited many in the community, even though apple didn’t build it.
Would it make sense to hold APINotes to a similar bar as Clang Modules originally were?
-Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20201006/c4f1f0a2/attachment.html>
More information about the cfe-dev
mailing list