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?
to your account
SE-0095 has been accepted, and we need an implementation. This consists of a few straight-forward pieces of work:
"Parse" the "P1 & P2" style syntax in the type production grammar.
Enhance PreCheckExpression to combine "P1 & P2" into a TypeExpr to cover the expression grammar case.
Make Any be a keyword, and make it generate the same AST as we form for protocol<> today.
Change the parser logic for the protocol<P1,P2> syntax to generate a warning+fixit for the new syntax.
Upgrade that warning to an error a couple of weeks later.
I'd suggest keeping the AST representation exactly the same as we have now for simplicity.
The text was updated successfully, but these errors were encountered:
Comment by Josef Willsher (JIRA)
Hi Chris, I’d like to take up work on this.
I’ve already done some work on the parsing; once I get Git working properly progress will be here https://github.com/joewillsher/swift
Sorry, something went wrong.
Sounds great!( Please send PR's for each small piece (which can be individually tested) as you make progress. Thanks)
My initial work is here joewillsher@d5eb88b25cbeaecf5127f9496db9faed4075473d, I’m updating the tests now.
Also this change doesn't affect SIL syntax does it? The proposal doesn't mention it but it feels like a strange inconsistency for it to continue using the protocol<...> syntax.
We should discuss what to do with the SIL syntax on the swift-dev list. The most important/time critical part is to sort out the ".swift" syntax issue.
Great, first PR here: #3293
@lattner I think [the PR](#3293 is ready to test and merge; I only have changing the demangler/printer’s syntax left, which I will do in a follow up PR.
That is complete too, as well as code completion for the Any keyword.
The tests are all passing; attr/attr_objc.swift seems to be crashing but I don’t think it is related to the parser/type system changes I made.
No branches or pull requests