|
FreeTensor
|
#include <rational.h>

Public Member Functions | |
| Rational (T p=0, T q=1) | |
| Rational & | operator+= (const Rational< T > &other) |
| Rational & | operator-= (const Rational< T > &other) |
| Rational & | operator*= (const Rational< T > &other) |
| Rational & | operator/= (const Rational< T > &other) |
| Rational | operator- () const |
Public Attributes | |
| T | p_ |
| T | q_ |
Friends | |
| bool | operator== (const Rational< T > &lhs, const Rational< T > &rhs) |
| Rational | operator+ (const Rational< T > &lhs, const Rational< T > &rhs) |
| Rational | operator- (const Rational< T > &lhs, const Rational< T > &rhs) |
| Rational | operator* (const Rational< T > &lhs, const Rational< T > &rhs) |
| Rational | operator/ (const Rational< T > &lhs, const Rational< T > &rhs) |
| std::ostream & | operator<< (std::ostream &os, const Rational< T > &r) |
| auto | operator<=> (const Rational< T > &lhs, const Rational< T > &rhs) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
| T freetensor::Rational< T >::p_ |
| T freetensor::Rational< T >::q_ |