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

opt: add volatility info for Unknown to Tuple cast #50436

Merged
merged 1 commit into from
Jun 20, 2020

Conversation

RaduBerinde
Copy link
Member

Casts from Unknown to any type are allowed as a special case, but we had no cast
defined from Unknown to Tuple (leading to an assertion error). This change adds
this missing information. I checked that now all type families define a cast
from Unknown.

Fixes #50258.

Release note (bug fix): fix recently introduced "no volatility for cast
unknown::tuple" error.

@RaduBerinde RaduBerinde requested a review from otan June 19, 2020 17:17
@RaduBerinde RaduBerinde requested a review from a team as a code owner June 19, 2020 17:17
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@RaduBerinde RaduBerinde requested a review from rohany June 19, 2020 20:59
Copy link
Contributor

@rohany rohany left a comment

Choose a reason for hiding this comment

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

Is there an easy way to ensure that we don't forget null -> t casts in the future?

@RaduBerinde
Copy link
Member Author

TFTR! Added a test.

@RaduBerinde
Copy link
Member Author

bors r+

@RaduBerinde
Copy link
Member Author

bors r-

@craig
Copy link
Contributor

craig bot commented Jun 19, 2020

Canceled

Casts from Unknown to any type are allowed as a special case, but we had no cast
defined from Unknown to Tuple (leading to an assertion error). This change adds
this missing information. I checked that now all type families define a cast
from Unknown.

Fixes cockroachdb#50258.

Release note (bug fix): fix recently introduced "no volatility for cast
unknown::tuple" error.
@RaduBerinde
Copy link
Member Author

bors r+

@craig
Copy link
Contributor

craig bot commented Jun 20, 2020

Build succeeded

@craig craig bot merged commit eb69237 into cockroachdb:master Jun 20, 2020
@RaduBerinde RaduBerinde deleted the fix-volatility-crash branch June 28, 2020 16:46
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.

roachtest: no volatility for cast sqlsmith/setup=empty/setting=default failed
3 participants