Changeset 7d7ef6f for libcfa/src
- Timestamp:
- Feb 17, 2022, 2:35:23 PM (2 years ago)
- Branches:
- ADT, ast-experimental, enum, forall-pointer-decay, master, pthread-emulation, qualifiedEnum
- Children:
- a556492
- Parents:
- 51b8582
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/math.trait.hfa
r51b8582 r7d7ef6f 16 16 #pragma once 17 17 18 trait Not( T) {19 void ?{}( T&, zero_t );20 int !?( T);18 trait Not( U ) { 19 void ?{}( U &, zero_t ); 20 int !?( U ); 21 21 }; // Not 22 22 … … 26 26 }; // Equality 27 27 28 trait Relational( T | Equality( T) ) {29 int ?<?( T, T);30 int ?<=?( T, T);31 int ?>?( T, T);32 int ?>=?( T, T);28 trait Relational( U | Equality( U ) ) { 29 int ?<?( U, U ); 30 int ?<=?( U, U ); 31 int ?>?( U, U ); 32 int ?>=?( U, U ); 33 33 }; // Relational 34 34 … … 39 39 }; // Signed 40 40 41 trait Additive( T | Signed( T) ) {42 T ?+?( T, T);43 T ?-?( T, T);44 T ?+=?( T &, T);45 T ?-=?( T &, T);41 trait Additive( U | Signed( U ) ) { 42 U ?+?( U, U ); 43 U ?-?( U, U ); 44 U ?+=?( U &, U ); 45 U ?-=?( U &, U ); 46 46 }; // Additive 47 47 … … 49 49 void ?{}( T &, one_t ); 50 50 // T ?++( T & ); 51 // T ++?( T & );51 // T ++?( T & ); 52 52 // T ?--( T & ); 53 53 // T --?( T & ); 54 54 }; // Incdec 55 55 56 trait Multiplicative( T | Incdec( T) ) {57 T ?*?( T, T);58 T ?/?( T, T);59 T ?%?( T, T);60 T ?/=?( T &, T);56 trait Multiplicative( U | Incdec( U ) ) { 57 U ?*?( U, U ); 58 U ?/?( U, U ); 59 U ?%?( U, U ); 60 U ?/=?( U &, U ); 61 61 }; // Multiplicative 62 62
Note: See TracChangeset
for help on using the changeset viewer.