Skip to content

gg: fix X11 C aliases for gg import - #27586

Merged
medvednikov merged 1 commit into
vlang:masterfrom
GGRei:fix-gg-x11-c-aliases
Jun 28, 2026
Merged

gg: fix X11 C aliases for gg import#27586
medvednikov merged 1 commit into
vlang:masterfrom
GGRei:fix-gg-x11-c-aliases

Conversation

@GGRei

@GGRei GGRei commented Jun 28, 2026

Copy link
Copy Markdown
Contributor

Summary

Fix #27584

This restores V1 compatibility for importing gg on Linux after the X11 Sokol aliases were changed to preserve C typedef names for V3.

The fix defines the missing X11 C.* scalar aliases locally, while keeping the public aliases backed by C.XID, C.Atom, C.Window, C.KeySym, etc. This lets V1 type-check the X11 scalar operations again without reverting the V3 C ABI work.

A focused regression test was added for the user-facing case: a minimal program importing gg.

Validation

  • ./v test vlib/v/tests/gg_import_check_test.v
  • ./v test vlib/v3/tests/x11_source_abi_alias_codegen_test.v
  • ./v fmt -verify vlib/sokol/sapp/sapp_linux.c.v vlib/sokol/sapp/sapp_x11_linux.v vlib/v/tests/project_issue_27584_gg_import_check_test.v
  • ./v -check vlib/v/tests/skip_unused/gg_code.vv
  • ./v test vlib/v/tests/fixed_array_update_c_struct_alias_test.v
  • ./v -silent test vlib/gg/
  • V1 examples/tetris/tetris.v: compile + short run
  • V3/C examples/tetris/tetris.v: compile + short run

@medvednikov
medvednikov merged commit badd346 into vlang:master Jun 28, 2026
4 of 90 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.

gg: the module is broken

2 participants