Skip to content

Commit 1a6f9da

Browse files
committed
πŸ§‘β€πŸ’» Min and max for base types
1 parent 505f0a6 commit 1a6f9da

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

β€ŽMarlin/src/core/types.h

+6-6
Original file line numberDiff line numberDiff line change
@@ -348,9 +348,9 @@ struct XYval {
348348
// If any element is true then it's true
349349
FI operator bool() { return x || y; }
350350
// Smallest element
351-
FI T _min() const { return _MIN(x, y); }
351+
FI T small() const { return _MIN(x, y); }
352352
// Largest element
353-
FI T _max() const { return _MAX(x, y); }
353+
FI T large() const { return _MAX(x, y); }
354354

355355
// Explicit copy and copies with conversion
356356
FI XYval<T> copy() const { return *this; }
@@ -505,9 +505,9 @@ struct XYZval {
505505
// If any element is true then it's true
506506
FI operator bool() { return NUM_AXIS_GANG(x, || y, || z, || i, || j, || k, || u, || v, || w); }
507507
// Smallest element
508-
FI T _min() const { return _MIN(NUM_AXIS_LIST(x, y, z, i, j, k, u, v, w)); }
508+
FI T small() const { return _MIN(NUM_AXIS_LIST(x, y, z, i, j, k, u, v, w)); }
509509
// Largest element
510-
FI T _max() const { return _MAX(NUM_AXIS_LIST(x, y, z, i, j, k, u, v, w)); }
510+
FI T large() const { return _MAX(NUM_AXIS_LIST(x, y, z, i, j, k, u, v, w)); }
511511

512512
// Explicit copy and copies with conversion
513513
FI XYZval<T> copy() const { XYZval<T> o = *this; return o; }
@@ -660,9 +660,9 @@ struct XYZEval {
660660
// If any element is true then it's true
661661
FI operator bool() { return 0 LOGICAL_AXIS_GANG(|| e, || x, || y, || z, || i, || j, || k, || u, || v, || w); }
662662
// Smallest element
663-
FI T _min() const { return _MIN(LOGICAL_AXIS_LIST(e, x, y, z, i, j, k, u, v, w)); }
663+
FI T small() const { return _MIN(LOGICAL_AXIS_LIST(e, x, y, z, i, j, k, u, v, w)); }
664664
// Largest element
665-
FI T _max() const { return _MAX(LOGICAL_AXIS_LIST(e, x, y, z, i, j, k, u, v, w)); }
665+
FI T large() const { return _MAX(LOGICAL_AXIS_LIST(e, x, y, z, i, j, k, u, v, w)); }
666666

667667
// Explicit copy and copies with conversion
668668
FI XYZEval<T> copy() const { XYZEval<T> v = *this; return v; }

0 commit comments

Comments
Β (0)