[PATCH] D67567: New ClangTidy check to warn when storing dispatch_once_t in non-static, non-global storage
Michael Wyman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 13 15:47:29 PDT 2019
mwyman added a comment.
In D67567#1670035 <https://reviews.llvm.org/D67567#1670035>, @lebedev.ri wrote:
> In D67567#1670017 <https://reviews.llvm.org/D67567#1670017>, @mwyman wrote:
>
> > In D67567#1669866 <https://reviews.llvm.org/D67567#1669866>, @lebedev.ri wrote:
> >
> > > 1. Please split each check into separate review.
> > > 2. Is `dispatch_once_t` OSX-specific thing? Should those checks be in `osx` module?
> >
> >
> >
> >
> > 1. I split the review.
>
>
>
>
> > 2. I don't see an `osx` module—am I somehow missing seeing it?
>
> One can be added.
>
> > `dispatch_once_t` is something from `libdispatch`which is an Apple-created API, but is OSS and available outside Apple. It's also a C API, which is why I didn't feel `objc` was an appropriate module either. I'm open to a better home module for this check, it's just not clear to me where that might be.
>
> No opinion on my question, just thought it should be asked,
As Ben commented, I don't feel this should be in an `osx` module, as libdispatch is highly used on iOS and other Apple platforms. I know it's available elsewhere, but it may be so seldom used that I think a `darwin`module might be reasonable. I looked at the process for creating a new module, and can do that if we'd like, but should that be part of this same review?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D67567/new/
https://reviews.llvm.org/D67567
More information about the cfe-commits
mailing list