Skip to content

test(rust): update C differential fixtures for by-value members - #16

Merged
sleevetosleeve merged 1 commit into
vlm_masterfrom
vibe/fix-rust-c-fixture-by-value-members-5999f1
Nov 26, 2026
Merged

sleevetosleeve merged 1 commit into
vlm_masterfrom
vibe/fix-rust-c-fixture-by-value-members-5999f1

Conversation

@sleevetosleeve

Copy link
Copy Markdown
Owner

Summary

  • Commit a7346cc (PR fix(compiler): emit by-value members for non-recursive type references #4, "emit by-value members for non-recursive type references") changed the generated C struct layout: mandatory non-recursive reference members are now embedded by value (Inner_t child;) instead of pointers (struct Inner *child;).
  • The tests-c-compiler fixtures were adapted at the time, but the hand-written C differential fixtures under tests/tests-rust-compiler were missed — that commit's validation skipped the Rust tests for lack of a local toolchain, so the first CI run with Cargo (runs 45842158366 / 45842158283) failed to compile them.
  • This PR updates all seven affected fixtures from pointer form (&inner, ->child, !decoded->child) to by-value form (inner, decoded->child.number). OPTIONAL members remain pointers and keep their original form. No compiler or skeleton changes; wire format is unchanged.

Affected fixtures:

  • c_named_sequence_record.c
  • c_named_sequence_empty.c
  • c_named_set_child.c
  • c_boolean_storage.c
  • imported_record_composition.c
  • imported_record_owned_defaults.c
  • imported_record_legacy.c

Related issues

  • Fixes the check-rust-backend.sh and check-rust-bitsets.sh failures from CI runs 45842158366 and 45842158283.

Type of change

  • Bug fix
  • New feature
  • Refactoring / docs / build

Testing

  • Built the compiler from source (hand-rolled build with bison 3.8.2 / flex 2.6.4 / gcc 14) and ran the full Rust test suite locally with cargo 1.100.0:
    • check-rust-backend.sh — full pass (end-to-end, including all C differential fixtures, strict Clippy, and ASan/UBSan-sanitized builds)
    • check-rust-bitsets.sh — pass
    • check-rust-aliases.sh — pass
    • check-rust-constraint-ranges.sh — pass
    • check-rust-strict-mode.sh — pass

Checklist

  • Up to date with vlm_master
  • CI passes (once Actions is enabled)
  • Docs/ChangeLog updated if behavior changed (no behavior change — test fixtures only)

Commit a7346cc emits mandatory non-recursive reference members by
value instead of as pointers, but the hand-written C fixtures under
tests/tests-rust-compiler were never adapted (its validation skipped
the Rust tests for lack of a toolchain), so the first CI run with
Cargo failed to compile them.

Update the seven affected fixtures from pointer (&x, ->, !member)
to by-value (.x, member.field) usage. OPTIONAL members remain
pointers and keep the original form.

Fixes the check-rust-backend.sh and check-rust-bitsets.sh failures
in runs 45842158366 and 45842158283.

Co-authored-by: sleevetosleeve <sleevetosleeve@users.noreply.github.com>
@sleevetosleeve
sleevetosleeve marked this pull request as ready for review November 26, 2026 18:26
@sleevetosleeve
sleevetosleeve merged commit 76c226d into vlm_master Nov 26, 2026
4 checks passed
@sleevetosleeve
sleevetosleeve deleted the vibe/fix-rust-c-fixture-by-value-members-5999f1 branch November 26, 2026 18:27
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.

2 participants