Skip to content

v: allow option array element comparison == and !=#23113

Merged
spytheman merged 2 commits intovlang:masterfrom
felipensp:fix_option_indexexpr_eq
Dec 9, 2024
Merged

v: allow option array element comparison == and !=#23113
spytheman merged 2 commits intovlang:masterfrom
felipensp:fix_option_indexexpr_eq

Conversation

@felipensp
Copy link
Copy Markdown
Member

@felipensp felipensp commented Dec 9, 2024

Comment thread vlib/v/tests/options/option_indexexpr_eq_test.v
@spytheman spytheman marked this pull request as ready for review December 9, 2024 18:33
@spytheman spytheman merged commit bc7a844 into vlang:master Dec 9, 2024
@spytheman
Copy link
Copy Markdown
Contributor

I've merged it without the additional tests for now, since I do not want to wait for their CI, before making a release, but I really do think that the tests should be added.

There were times in the past already, where the implementation for the options and generics types had hysteresis, and things that normally worked in isolation, broke when used in the same function due to that.

@felipensp felipensp deleted the fix_option_indexexpr_eq branch December 9, 2024 18:40
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.

allow "unwrapped Option cannot be used in an infix expression"

2 participants