Skip to content
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

Tiny cleanup of CloningExpressionVisitor #30700

Merged
merged 1 commit into from
Apr 17, 2023
Merged

Tiny cleanup of CloningExpressionVisitor #30700

merged 1 commit into from
Apr 17, 2023

Conversation

roji
Copy link
Member

@roji roji commented Apr 16, 2023

Convert to switch and some tiny stuff.

@roji roji requested a review from maumar April 16, 2023 15:31
}
// join and set operations are fine, because they contain other TableExpressionBases inside, that will get cloned
// and therefore set expression's Update function will generate a new instance.
case JoinExpressionBase or SetOperationBase:
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@maumar note using the base classes for joins/set operations rather than listing them out

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my thinking was that if we introduce new join/set expression that happens to need cloning logic, we would need to explicitly make the decision, rather than being covered by base. But now that I think about it, it was overkill.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. I think your logic (as in the comment) should hold for any subclass of JoinExpressionBase/SetOperationBase... We can see where it goes...

@roji roji merged commit e007d7c into dotnet:main Apr 17, 2023
@roji roji deleted the TinyCleanup branch April 17, 2023 21:14
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.

2 participants