Extracting attributes
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 2.4k
- Forks
- 237
- PR merge metrics
- No merged PRs in 30d
Description
I tried adding support for parsing attributes defined via __attribute__ in ObjC in order to mark unavailable/deprecated methods in Jazzy.
While I can get the attributes by processing the CXCursor_UnexposedAttr cursors, those seem not to include any information such as attribute name/value, only the original declaration, without macros expanded.
Can someone with more Clang know-how explain what would be the best way to expand those declarations and correctly process the attribute declarations.
P.S. I also briefly looked into SourceKit support for @available in Swift. The version shipping with Xcode 7.3.1 seems to emit only the entry with attribute name, without other parameters :(
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how SourceKitten handles CXCursor_UnexposedAttr cursors and compare the available declaration information with the needed attribute names and values. Investigate the related SourceKit behavior for Swift @available parameters; done means establishing a concrete approach for correctly extracting both kinds of attribute data.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- objective-c, swift
- Domain
- compilers, devtools
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100