-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swift file could not be parsed #18
Comments
Thanks for filing this, @emaloney. Does your project build successfully when running |
It seems to work for me when I run the following: sourcekitten --single-file `pwd`/BasicDeepLinkSupportConfiguration.swift -j4 `pwd`/BasicDeepLinkSupportConfiguration.swift Can you try that from your end? |
Yes, if I just do a plain old I am also invoking FWIW, I'm using an |
Since I can't reproduce with just the file, I'll need access to the full project to help troubleshoot, unfortunately. We could also screenshare if you can't send me the full source. Alternatively, you could troubleshoot on your end by running sourcekitten in a debug session in Xcode. But that's actually bit complex to explain how to do properly since sourcekitten will spawn a new process for each file. |
I don't have I will install it and try |
Below is what I get when I run However, if I run {
"key.substructure" : [
{
"key.kind" : "source.lang.swift.decl.class",
"key.offset" : 530,
"key.attributes" : [
{
"key.attribute" : "source.decl.attribute.private"
},
{
"key.attribute" : "source.decl.attribute.__raw_doc_comment"
}
],
"key.nameoffset" : 536,
"key.namelength" : 33,
"key.inheritedtypes" : [
{
"key.name" : "DeepLinkRouterConfigurationImpl"
}
],
"key.bodylength" : 258,
"key.runtime_name" : "_TtC8__main__33BasicDeepLinkSupportConfiguration",
"key.substructure" : [
{
"key.kind" : "source.lang.swift.decl.function.method.instance",
"key.offset" : 661,
"key.attributes" : [
{
"key.attribute" : "source.decl.attribute.private"
},
{
"key.attribute" : "source.decl.attribute.override"
},
{
"key.attribute" : "source.decl.attribute.__raw_doc_comment"
}
],
"key.nameoffset" : 661,
"key.namelength" : 6,
"key.bodyoffset" : 673,
"key.bodylength" : 187,
"key.length" : 200,
"key.substructure" : [
],
"key.name" : "init()"
}
],
"key.name" : "BasicDeepLinkSupportConfiguration",
"key.length" : 333,
"key.bodyoffset" : 604
}
],
"key.offset" : 0,
"key.diagnostic_stage" : "source.diagnostic.stage.swift.parse",
"key.length" : 864
} |
I will see if I can whittle down the issue to a subset of our source tree in hopes of pinpointing the problem. If I can get it to a small enough set of code to share, I will send it along. Otherwise, I appreciate your offer of screensharing and may have to take you up on it. I'll be away for the remainder of the weekend, but will look into this again early next week. Thanks for your help, and for your contributions to |
Hi JP, I've just e-mailed you with some more information to reproduce the issue. I've narrowed the problem down to a specific line. E. |
What's neat is that this bug never would have happened if Array subscript returned an optional, since it would have enforced proper "bounds checking". |
Add features to misc_jazzy_features fixture for testing documentation…
Hello,
I am opening this ticket in response to a new error encountered while using the jazzy documentation generator:
"BasicDeepLinkSupportConfiguration.swift could not be parsed. Please open an issue at https://github.com/jpsim/sourcekitten/issues with the file contents."
So, as requested, that's what I'm doing. :)
The content of the file in question is:
I'm encountering this error using jazzy 0.0.19 and 0.0.20.
Please let me know if there's more information I can provide that will be helpful.
Thanks!
Evan
The text was updated successfully, but these errors were encountered: