Skip to content

__BLOCKS__ should not be defined when running IntelliSense with clang #6189

@sean-mcmanus

Description

@sean-mcmanus

...because our IntelliSense parser doesn't have support for blocks, but we get back __BLOCKS__=1 when querying clang compilers on Mac. This could potentially break IntelliSense with any code that checks __BLOCKS__ and uses ^ blocks syntax (http://clang.llvm.org/docs/BlockLanguageSpec.html).

The fix (and workaround) is to pass -fno-blocks when querying clang compilers (with Mac clang -fblocks is the default)...the main difficulty to is to avoid using -fno-blocks with gcc, which doesn't support that flag.

Metadata

Metadata

Assignees

Labels

Language ServicebugfixedCheck the Milestone for the release in which the fix is or will be available.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions