From d48f050cb0209a4ba9819a094ffd1e7a7c2524ee Mon Sep 17 00:00:00 2001 From: kaizhangNV <149626564+kaizhangNV@users.noreply.github.com> Date: Wed, 25 Jun 2025 12:01:54 -0500 Subject: Fix ambiguous reference for 'extern' and 'export' (#7515) Close #7509. When there are both `export` and `extern` decls in lookup result, we should remove all `extern` decls. --- tests/library/ambiguous-extern-export-lib2.slang | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 tests/library/ambiguous-extern-export-lib2.slang (limited to 'tests/library/ambiguous-extern-export-lib2.slang') diff --git a/tests/library/ambiguous-extern-export-lib2.slang b/tests/library/ambiguous-extern-export-lib2.slang new file mode 100644 index 000000000..08d01fb04 --- /dev/null +++ b/tests/library/ambiguous-extern-export-lib2.slang @@ -0,0 +1,15 @@ + +module "ambiguous-extern-export-lib2.slang"; + +public extern static const int call_data_len; +public extern static const int[call_data_len] call_group_vector; + +public static int[call_data_len] call_id_2 = {}; + +public void initCallId2() +{ + for (int i = 0; i < call_data_len; i++) + { + call_id_2[i] = call_group_vector[i]; + } +} -- cgit v1.2.3