1
5
mirror of https://github.com/vinc/moros.git synced 2024-06-18 23:17:04 +00:00
moros/src/usr/mod.rs
Vincent Ollivier 892b697bd3
Add BigInt support to Lisp (#415)
* Add bigint support to Lisp

* Remove Box

* Replace BigInt by i64

* Add back big int

* Work around big int errors

* Print floats with a dot

* Add conversion to f64

* Use Number#parse instead of double

* Add trigo functions to Number

* Add conversion from number to byte

* Add addition to Number

* Add multiplication to Number

* Add negation and substraction to Number

* Add division to Number

* Add reminder to Number

* Add pow to Number

* Fix tests

* Re-enable BigInt

* Add parsing and printing of BigInt

* Add sign

* Add operations on BigInt

* Fix compilation issues

* Add support for add and mul overflow

* Fix bigint conversion to and from str

* Add number-type function

* Add tests

* Add support for pow overflow

* Fix tests

* Add more checks for overflow

* Add check for division by zero

* Fix typo

* Return inf for large exponential operations

* Check for division by zero in modulo

* Add shift operations

* Rewrite comparisons

* Add lazy eval to cond expressions

* Add set fonction

* Add loop function

* Add pi example

* Add builtin pi example to shell

* Update allocation error messages

* Rewrite number conversions

* Remove debug output from pi example

* Move pi command to a dedicated file

* Rewrite bytes->number and number->bytes

* Update doc

* Move op impl to Number

* Add macros to dry code

* Add more macros

* Run clippy
2022-10-17 20:58:08 +02:00

40 lines
564 B
Rust

pub mod base64;
pub mod beep;
pub mod calc;
pub mod chess;
pub mod colors;
pub mod copy;
pub mod date;
pub mod delete;
pub mod dhcp;
pub mod disk;
pub mod editor;
pub mod elf;
pub mod env;
pub mod find;
pub mod geotime;
pub mod help;
pub mod hex;
pub mod host;
pub mod http;
pub mod httpd;
pub mod install;
pub mod keyboard;
pub mod life;
pub mod lisp;
pub mod list;
pub mod memory;
pub mod net;
pub mod pci;
pub mod pi;
pub mod pow;
pub mod r#move;
pub mod read;
pub mod shell;
pub mod socket;
pub mod tcp;
pub mod time;
pub mod user;
pub mod vga;
pub mod write;