Changes in src/libcfa/rational [53a6c2a:7bc4e6b]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/libcfa/rational
r53a6c2a r7bc4e6b 12 12 // Created On : Wed Apr 6 17:56:25 2016 13 13 // Last Modified By : Peter A. Buhr 14 // Last Modified On : Fri Jul 7 09:34:33201715 // Update Count : 9 314 // Last Modified On : Wed Aug 23 22:35:09 2017 15 // Update Count : 95 16 16 // 17 17 … … 31 31 int ?>?( T, T ); 32 32 int ?>=?( T, T ); 33 void ?{}( T *, zero_t );34 void ?{}( T *, one_t );33 void ?{}( T &, zero_t ); 34 void ?{}( T &, one_t ); 35 35 T +?( T ); 36 36 T -?( T ); … … 40 40 T ?/?( T, T ); 41 41 T ?%?( T, T ); 42 T ?/=?( T *, T );42 T ?/=?( T &, T ); 43 43 T abs( T ); 44 44 }; … … 54 54 55 55 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 56 void ?{}( Rational(RationalImpl) *r );56 void ?{}( Rational(RationalImpl) & r ); 57 57 58 58 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 59 void ?{}( Rational(RationalImpl) *r, RationalImpl n );59 void ?{}( Rational(RationalImpl) & r, RationalImpl n ); 60 60 61 61 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 62 void ?{}( Rational(RationalImpl) *r, RationalImpl n, RationalImpl d );62 void ?{}( Rational(RationalImpl) & r, RationalImpl n, RationalImpl d ); 63 63 64 64 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 65 void ?{}( Rational(RationalImpl) *r, zero_t );65 void ?{}( Rational(RationalImpl) & r, zero_t ); 66 66 67 67 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 68 void ?{}( Rational(RationalImpl) *r, one_t );68 void ?{}( Rational(RationalImpl) & r, one_t ); 69 69 70 70 // numerator/denominator getter … … 77 77 78 78 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 79 [ RationalImpl, RationalImpl ] ?=?( *[ RationalImpl, RationalImpl ] dest, Rational(RationalImpl) src );79 [ RationalImpl, RationalImpl ] ?=?( & [ RationalImpl, RationalImpl ] dest, Rational(RationalImpl) src ); 80 80 81 81 // numerator/denominator setter … … 135 135 // I/O 136 136 forall( otype RationalImpl | arithmetic( RationalImpl ) ) 137 forall( dtype istype | istream( istype ) | { istype * ?|?( istype *, RationalImpl *); } )138 istype * ?|?( istype *, Rational(RationalImpl) *);137 forall( dtype istype | istream( istype ) | { istype * ?|?( istype *, RationalImpl & ); } ) 138 istype * ?|?( istype *, Rational(RationalImpl) & ); 139 139 140 140 forall( otype RationalImpl | arithmetic( RationalImpl ) )
Note:
See TracChangeset
for help on using the changeset viewer.