Skip to content

Conversation

@felipensp
Copy link
Member

Fix #23723

@huly-for-github
Copy link

Connected to Huly®: V_0.6-22147

}

fn test_main() {
c := chan Message{}
Copy link
Member

Choose a reason for hiding this comment

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

hm, why is c := chan Message{} needed, and why there is not a warning, that it is not used later?

Comment on lines +204 to +206
defer {
g.last_if_option_type = tmp_if_option_type
}
Copy link
Member

Choose a reason for hiding this comment

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

move the defer after line 197

Copy link
Member

Choose a reason for hiding this comment

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

it will be much less error prone that way, and it will work when the defer becomes scope based

Copy link
Member

@spytheman spytheman left a comment

Choose a reason for hiding this comment

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

Good work.

@spytheman spytheman marked this pull request as ready for review February 15, 2025 20:53
@spytheman spytheman merged commit f4aa139 into vlang:master Feb 15, 2025
72 checks passed
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.

C compilation error with generics and nested if expressions

2 participants