Skip to content

Conversation

@simeonschaub
Copy link
Member

I don't know why we previously emitted an SSA value here. We only accept
bools in if-conditions, so I don't see how g could be anything but
true inside the first clause.

fixes #43130

I don't know why we previously emitted an SSA value here. We only accept
bools in if-conditions, so I don't see how `g` could be anything but
`true` inside the first clause.

fixes #43130
@simeonschaub simeonschaub added compiler:inference Type inference compiler:lowering Syntax lowering (compiler front end, 2nd stage) labels Nov 19, 2021
@vtjnash vtjnash added the merge me PR is reviewed. Merge when all tests are passing label Nov 19, 2021
@vtjnash
Copy link
Member

vtjnash commented Nov 19, 2021

In runtime, that is true, but at compile-time, true could be additionally refined to remain as a Conditional object. So I am surprised this works, but happy that it does, without needing to look any closer at how exactly this worked out.

@simeonschaub
Copy link
Member Author

That should all happen way later though. I just meant lowering explicitly creating an ssavalue here and using that in both the condition and the body.

@simeonschaub simeonschaub merged commit 2c057f8 into master Nov 19, 2021
@simeonschaub simeonschaub deleted the sds/or_constraints branch November 19, 2021 03:37
@DilumAluthge DilumAluthge removed the merge me PR is reviewed. Merge when all tests are passing label Nov 19, 2021
simeonschaub added a commit that referenced this pull request Dec 2, 2021
aviatesk pushed a commit that referenced this pull request Dec 2, 2021
LilithHafner pushed a commit to LilithHafner/julia that referenced this pull request Feb 22, 2022
I don't know why we previously emitted an SSA value here. We only accept
bools in if-conditions, so I don't see how `g` could be anything but
`true` inside the first clause.

fixes JuliaLang#43130
LilithHafner pushed a commit to LilithHafner/julia that referenced this pull request Feb 22, 2022
LilithHafner pushed a commit to LilithHafner/julia that referenced this pull request Mar 8, 2022
I don't know why we previously emitted an SSA value here. We only accept
bools in if-conditions, so I don't see how `g` could be anything but
`true` inside the first clause.

fixes JuliaLang#43130
LilithHafner pushed a commit to LilithHafner/julia that referenced this pull request Mar 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

compiler:inference Type inference compiler:lowering Syntax lowering (compiler front end, 2nd stage)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

possible type constraint propagation from !(a && b) pattern

4 participants