wcc: single-dot field compound assignment routes through one combine helper
s.f *= v silently became s.f = v (and the other non-+=/-= ops dropped likewise) in BOTH stages across five lvalue sub-arms: via-ptr field, direct local field, str/slice pseudo-field, and the two global-field forms. Funnel all five through a shared combine dispatch (cgdotfieldcombine / cg_dotfield_combine) emitting the load-OP-store sequence at field width, hard-erroring the unhandled kinds — close-by- construction so no arm stays on the old PLUSEQ-only path (the #133 BUS-routing lesson; #227 sites A/B are the closed siblings). The refactor routes the corpus's existing +=/-= sites through the same helper output-identically (byte-id held). Review item #34. Both stages move in one commit: one emission contract; splitting the halves would leave the byte-id gates red in between.
This commit is contained in:
7
Makefile
7
Makefile
@@ -323,6 +323,7 @@ TESTS = $(BIN)/test_smoke $(BIN)/test_lex $(BIN)/test_parse $(BIN)/test_check \
|
||||
$(BIN)/test_nullable_try_run \
|
||||
$(BIN)/test_nullable_assert_run \
|
||||
$(BIN)/test_idxfield_compound_run \
|
||||
$(BIN)/test_dotfield_compound_run \
|
||||
$(BIN)/test_nested_union_widen_run \
|
||||
$(BIN)/test_sret_struct_return \
|
||||
$(BIN)/test_sret_struct_return_run \
|
||||
@@ -1785,6 +1786,12 @@ $(BIN)/test_idxfield_compound_run: test/wcc/949_idxfield_compound_run.c \
|
||||
$(LIB)/libwwrt.a | $(BIN)
|
||||
$(CC) $(CFLAGS) -o $@ $<
|
||||
|
||||
$(BIN)/test_dotfield_compound_run: test/wcc/949_dotfield_compound_run.c \
|
||||
$(BIN)/ww $(BIN)/w6c $(BIN)/w6a $(BIN)/w6l \
|
||||
$(BIN)/ww_ww $(BIN)/w6c_ww $(BIN)/w6a_ww $(BIN)/w6l_ww \
|
||||
$(LIB)/libwwrt.a | $(BIN)
|
||||
$(CC) $(CFLAGS) -o $@ $<
|
||||
|
||||
$(BIN)/test_sret_struct_return: test/wcc/721_sret_struct_return.c \
|
||||
$(BIN)/w6c $(BIN)/w6c_ww | $(BIN)
|
||||
$(CC) $(CFLAGS) -o $@ $<
|
||||
|
||||
Reference in New Issue
Block a user