Mercury Bugs - mercury
View Issue Details
0000567mercuryBugpublic2023-11-07 13:002023-11-08 17:59
Reporterwangp 
Assigned Tozs 
PrioritynormalSeveritymajorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0000567: regression due to merging consecutive switches
DescriptionI have bisected a regression to commit 43dd12bd5b9608dcd150ea0c7bdc1e3f256f15d2
"Merge consecutive switches on the same variable."

See the attached test case.

This is incorrect:

% mmc -O2 regression_merge_switches && ./regression_merge_switches
header(field_name("Message-ID"), header_value("Tue, 7 Nov 2023 12:29:43 +1100"))
header(field_name("Message-ID"), header_value("<20231107122943.GB219@example>"))

The correct output is this:

% mmc -O1 regression_merge_switches && ./regression_merge_switches
header(field_name("Date"), header_value("Tue, 7 Nov 2023 12:29:43 +1100"))
header(field_name("Message-ID"), header_value("<20231107122943.GB219@example>"))
TagsNo tags attached.
Attached Files? regression_merge_switches.m (2,046) 2023-11-07 13:00
https://bugs.mercurylang.org/file_download.php?file_id=324&type=bug

Notes
(0001226)
zs   
2023-11-08 17:59   
Fix committed 2023 nov 8.

Issue History
2023-11-07 13:00wangpNew Issue
2023-11-07 13:00wangpFile Added: regression_merge_switches.m
2023-11-07 23:50zsAssigned To => zs
2023-11-07 23:50zsStatusnew => assigned
2023-11-08 17:59zsStatusassigned => resolved
2023-11-08 17:59zsResolutionopen => fixed
2023-11-08 17:59zsNote Added: 0001226