Expand description
Types for abstract mathematical computation.
Note, Documentation is currently lacking. The best way to learn about this framework is to read the tests and see how it is used to implement algorithms in Optimal.
§Examples
use computation_types::{named_args, val, Run};
let one_plus_one = val!(1) + val!(1);
assert_eq!(one_plus_one.to_string(), "(1 + 1)");
assert_eq!(one_plus_one.run(), 2);
Re-exports§
Modules§
Macros§
- arg
- arg1
- arg2
- impl_
computation_ fn_ for_ binary - impl_
computation_ fn_ for_ unary - impl_
core_ ops - impl_
display_ for_ inline_ binary - named_
args - names
- val
- val1
- val2
Structs§
Enums§
Traits§
- AnyArg
- Computation
- A type representing a computation.
- Computation
Fn - A type representing a function-like computation.