jpsim / SourceKitten

An adorable little framework and command line tool for interacting with SourceKit.
MIT License
2.31k stars 226 forks source link

Objective-C class properties cause SIGILL #243

Closed frankus closed 8 years ago

frankus commented 8 years ago

Declaring a class property in Objective-C:

@property (class, readonly, nonatomic) Foo *shared;

and running sourcekitten (arguments of doc -objc -- -x objective-c -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator10.0.sdk -I /path/to/project) against it fails with a terminated by signal SIGILL (Illegal instruction) error.

jpsim commented 8 years ago

huh, interesting... thanks for reporting this

jeremiegirault commented 8 years ago

more info here: private func accessorUSR(getter: Bool) -> String checks for py class properties contains a cpy tag force unwrap causes the crash

jeremiegirault commented 8 years ago

more: proposed a fix in #285

jpsim commented 8 years ago

Merged in #291. Thanks to @jeremiegirault and @frankus for reporting 😄