Skip to content

cgen: fix comptime for types not being recognized with maps correctly#25743

Merged
spytheman merged 1 commit into
vlang:masterfrom
dy-tea:comptime-map
Nov 15, 2025
Merged

cgen: fix comptime for types not being recognized with maps correctly#25743
spytheman merged 1 commit into
vlang:masterfrom
dy-tea:comptime-map

Conversation

@dy-tea

@dy-tea dy-tea commented Nov 15, 2025

Copy link
Copy Markdown
Member

Fixes #25742.

The way I mutate the ast is a bit hacky. If anyone can suggest a better place to do this let me know.

@spytheman

Copy link
Copy Markdown
Contributor

If anyone can suggest a better place to do this let me know.

Ideally, it should be in the transformer or the checker, but I am not sure how viable it is to move it there at the moment.

@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 @dy-tea 🙇🏻 .

@spytheman spytheman merged commit b2a0f68 into vlang:master Nov 15, 2025
84 checks passed
@dy-tea dy-tea deleted the comptime-map branch November 15, 2025 18:31
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.

comptime: struct fields as maps with different key/value types can't be deduced

2 participants