Skip to content

v0.4.1 (2024-03-30)

Compare
Choose a tag to compare
@github-actions github-actions released this 30 Mar 05:01
· 210 commits to main since this release

Release Notes

Breaking changes

  • Sexp loses is_environment() method becuase this isn't useful, considering
    savvy doesn't support environment.

New features

  • get_dim() and set_dim() are now available also on Sexp.

  • Now savvy allows to consume the value behind an external pointer. i.e., T
    instead of &T or &mut T as the argument. After getting consumed, the
    pointer is null, so any function call on the already-consumed R object results
    in an error. See the guide for more details.

    Example:

    struct Value {};
    struct Wrapper { inner: Value }
    
    #[savvy]
    impl Value {
      fn new() -> Self {
        Self {}
      }
    }
    
    #[savvy]
    impl Wrapper {
      fn new(value: Value) -> Self {
        Self { inner: value }
      }
    }
    v <- Value$new()
    w <- Wrapper$new(v)  # value is consumed here.
    
    w <- Wrapper$new(v)
    #> Error: This external pointer is already consumed or deleted
  • Sexp now has assert_integer() etc to verify the type of the underlying
    SEXP is as expected.

Download savvy-cli 0.4.1

File Platform Checksum
savvy-cli-aarch64-apple-darwin.tar.xz Apple Silicon macOS checksum
savvy-cli-x86_64-apple-darwin.tar.xz Intel macOS checksum
savvy-cli-x86_64-pc-windows-msvc.zip x64 Windows checksum
savvy-cli-aarch64-unknown-linux-gnu.tar.xz ARM64 Linux checksum
savvy-cli-x86_64-unknown-linux-gnu.tar.xz x64 Linux checksum