@@ -2041,7 +2041,11 @@ int cbm_build_registry_from_cache(cbm_pipeline_ctx_t *ctx, const cbm_file_info_t
20412041 }
20422042 }
20432043
2044- cbm_pipeline_namespace_map_free (namespace_map );
2044+ /* Publish instead of free: the call pass needs the same declared-package
2045+ * set to tell an in-tree package path from a third-party one (#1355).
2046+ * The pipeline owns it from here and frees it in its cleanup. */
2047+ cbm_pipeline_namespace_map_free (cbm_pipeline_get_nsmap ());
2048+ cbm_pipeline_set_nsmap (namespace_map );
20452049
20462050 cbm_log_info ("parallel.registry.done" , "entries" , itoa_log (reg_entries ), "defines" ,
20472051 itoa_log (defines_edges ), "imports" , itoa_log (imports_edges ));
@@ -3406,6 +3410,11 @@ static void resolve_file_calls(resolve_ctx_t *rc, resolve_worker_state_t *ws, CB
34063410 * This gate MUST stay identical to the one there. */
34073411 bool suppress_weak_local_binding = lang == CBM_LANG_PYTHON ;
34083412 /* The member guard's one exemption — MUST match pass_calls.c exactly. */
3413+ /* #1355: same guard as pass_calls.c, and joined to drop_plain_call for
3414+ * the same reason — a `continue` here would also skip route/HTTP/CONFIG
3415+ * classification, and a static-import route registration is a bare call
3416+ * bound by a package specifier. Suppress only the plain-CALLS
3417+ * fall-through so every Route node stays main-identical. */
34093418 bool drop_plain_call =
34103419 (cbm_suppress_weak_member_match (suppress_weak_member , call -> is_method , res .strategy ) &&
34113420 !cbm_weak_member_unique_name_exempt (lang == CBM_LANG_PYTHON ,
@@ -3422,6 +3431,9 @@ static void resolve_file_calls(resolve_ctx_t *rc, resolve_worker_state_t *ws, CB
34223431 cbm_python_import_binding_contradicts (& result -> imports , call -> callee_name ,
34233432 res .qualified_name , rc -> main_gbuf ,
34243433 rc -> project_name , rel )) ||
3434+ cbm_suppress_external_import_shadow (call -> callee_name , res .strategy , & result -> imports ,
3435+ imp_keys , imp_count , cbm_pipeline_get_pkgmap (),
3436+ cbm_pipeline_get_nsmap ()) ||
34253437 /* MUST match pass_calls.c exactly. */
34263438 (lang == CBM_LANG_PHP && cbm_suppress_weak_member_match (true, true, res .strategy ) &&
34273439 cbm_pipeline_php_receiver_type_unindexed (& result -> resolved_calls , call , rc -> registry ));
0 commit comments