File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -209,16 +209,16 @@ the enforcement from its nearest ancestor that has bounds:
209209```cpp
210210// Absolute origin with physical bounds:
211211template<>
212- inline constexpr auto mp_units::quantity_bounds<prime_meridian> = mp_units::clamp_to_range {-180.0 * deg, 180.0 * deg};
212+ inline constexpr auto mp_units::quantity_bounds<prime_meridian> = wrap_to_range {-180.0 * deg, 180.0 * deg};
213213
214214// Relative origin — no own bounds; inherits from prime_meridian.
215215// The +21° offset is transparent to the enforcement.
216216inline constexpr struct warsaw_meridian final : mp_units::relative_point_origin<prime_meridian + 21.0 * deg> {
217217} warsaw_meridian;
218218
219- // A value of +200° east of Warsaw = +221° from prime → clamped to +180° → +159 ° from Warsaw.
219+ // A value of +200° east of Warsaw = +221° from prime → wraps to -139° from prime → -160 ° from Warsaw.
220220quantity_point qp = warsaw_meridian + 200.0 * deg;
221- assert(qp.quantity_from(warsaw_meridian) == 159 .0 * deg);
221+ assert(qp.quantity_from(warsaw_meridian) == -160 .0 * deg);
222222```
223223
224224When a ` relative_point_origin ` defines ** its own** bounds, those bounds are
You can’t perform that action at this time.
0 commit comments