mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Fix for enumeration values not explicitly handled in switch statements
This commit is contained in:
parent
200bb92b9e
commit
670d7d0e22
5 changed files with 12 additions and 0 deletions
|
|
@ -295,6 +295,8 @@ std::vector<VolumeCalculation::Result> VolumeCalculation::execute() const
|
|||
case TriggerMetric::variance:
|
||||
val = result.volume[1] * result.volume[1];
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
// update max if entry is valid
|
||||
if (val > 0.0) { trigger_val = std::max(trigger_val, val); }
|
||||
|
|
@ -374,6 +376,8 @@ void VolumeCalculation::to_hdf5(const std::string& filename,
|
|||
case TriggerMetric::relative_error:
|
||||
trigger_str = "rel_err";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
write_attribute(file_id, "trigger_type", trigger_str);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue