Skip to content

[BuilderTransform] Replace use of TypeExpr with a special $builderSelf variable #42329

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

Merged
merged 2 commits into from
Apr 15, 2022

Conversation

xedin
Copy link
Contributor

@xedin xedin commented Apr 13, 2022

For all of the build* calls, let's use a special variable declaration
$builderSelf which refers to a type of the builder used. This allows
us to remove hacks related to use of TypeExpr. Reference to $builderSelf
is replaced with TypeExpr during solution application when the builder
type is completely resolved.

@xedin xedin requested a review from hborla April 13, 2022 00:53
@xedin
Copy link
Contributor Author

xedin commented Apr 15, 2022

@swift-ci please test

@CodaFi
Copy link
Contributor

CodaFi commented Apr 15, 2022

Can we call it $__builderSelf so it's user-inaccessible?

@xedin
Copy link
Contributor Author

xedin commented Apr 15, 2022

Or just $builderSelf then if that’s better, I just followed existing style of naming but will change it.

xedin added 2 commits April 14, 2022 21:16
…f variable

For all of the `build*` calls, let's use a special variable declaration
`$builderSelf` which refers to a type of the builder used. This allows
us to remove hacks related to use of `TypeExpr`. Reference to `$builderSelf`
is replaced with `TypeExpr` during solution application when the builder
type is completely resolved.
@xedin xedin changed the title [BuilderTransform] Replace use of TypeExpr with a special __builderSelf variable [BuilderTransform] Replace use of TypeExpr with a special $builderSelf variable Apr 15, 2022
@xedin
Copy link
Contributor Author

xedin commented Apr 15, 2022

@swift-ci please test

@xedin xedin merged commit 018cd08 into swiftlang:main Apr 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants