Fix missing namespace qualifier in Pack() (#8967)

* Fix missing namespace qualifier in Pack() for cross-namespace table references

* Fix missing namespace qualifier in Pack()

* Add cross_namespace_pack_test to Bazel build
This commit is contained in:
tmimmanuel
2026-03-12 02:11:06 +00:00
committed by GitHub
parent 9e3fe5d3f6
commit e35817577c
14 changed files with 111 additions and 45 deletions

View File

@@ -0,0 +1,18 @@
// Test for cross-namespace Pack() code generation (issue #8948).
// Verifies that Create* calls in Pack() are properly namespace-qualified
// when referencing tables from different namespaces.
namespace native;
table TableWithNative {
value: int;
}
namespace foo;
table Consumer {
c1: native.TableWithNative;
c2: [native.TableWithNative];
}
root_type Consumer;