Skip to content

Releases: fivemoreminix/rsc

v2.0

17 May 00:58
Compare
Choose a tag to compare
  • Real named functions! Functions are no longer tokens, and can now be created in a Computer, similar to variables.
let mut map = HashMap::<String, &'a Fn(f64) -> f64>::new();
map.insert("sqrt".to_owned(), &|n| n.sqrt());
  • RSC is fully generic, now! Types that can support addition, subtraction, and a couple functions necessary in the Num trait can be lexed, parsed, and computed with no changes to the RSC source code.
  • Getting the previous answer with the new ans variable. ans does not exist until you've run a calculation on a Computer already.
  • Factorial: 5! = 120

v1.2.0

01 Jan 02:21
Compare
Choose a tag to compare

Since v1.0.0:

  • v1.1.0's improvements
  • Many bug fixes to the parser
  • Better errors
  • Update to Rust 2018
  • Absolute value (abs -3 and |-3|)
  • Library documentation
  • Variables ((x = 3) + 2 becomes 5 and x becomes 3)

v1.0.0

12 Sep 00:37
Compare
Choose a tag to compare

The first officially complete version of RSC that can be used as or for commercial software.

Don't forget to check the Wiki for usage information.