Skip to content

cgen: fix tmp var redeclaration on const inited later code gen - #24524

Merged
spytheman merged 2 commits into
vlang:masterfrom
felipensp:fix_surround_tmp_var_declaration
May 19, 2025
Merged

spytheman merged 2 commits into
vlang:masterfrom
felipensp:fix_surround_tmp_var_declaration

Conversation

@felipensp

@felipensp felipensp commented May 19, 2025 •

Copy link
Copy Markdown
Member

Fix #24521
Fix #24517

@felipensp felipensp changed the title cgen; fix tmp var redeclaration on const inited later code gen cgen: fix tmp var redeclaration on const inited later code gen May 19, 2025
@huly-for-github

Copy link
Copy Markdown

Connected to Huly®: V_0.6-22892

Comment thread vlib/v/gen/c/consts_and_globals.v
@spytheman
spytheman force-pushed the fix_surround_tmp_var_declaration branch from 2cf7a63 to ce87a4d Compare May 19, 2025 12:50
@felipensp

Copy link
Copy Markdown
Member Author

Thanks @spytheman

@spytheman

Copy link
Copy Markdown
Contributor

(rebased over master, and added a minimal project as a regression test, using the code from #24521)

@spytheman

Copy link
Copy Markdown
Contributor

Thanks @spytheman

Happy to help 🙇🏻‍♂️ .

@spytheman
spytheman marked this pull request as ready for review May 19, 2025 12:53

@spytheman spytheman left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thank you for fixing it, in a more robust way @felipensp .

@spytheman
spytheman merged commit 18f1874 into vlang:master May 19, 2025
@felipensp
felipensp deleted the fix_surround_tmp_var_declaration branch May 19, 2025 13:21
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.

error: redeclaration of '_t1' Output of the C Compiler (cc)

2 participants