Skip to content

v0.4.0 (2024-03-27)

Compare
Choose a tag to compare
@github-actions github-actions released this 27 Mar 09:00
· 192 commits to main since this release

Release Notes

Breaking changes

  • #[savvy] on a struct's impl now generates the same name of R object that
    holds all the accociated functions. For example, previously the below code
    generates a constructor Person(), but now the constructor is available as
    Person$new().
struct Person {
    pub name: String,
}

/// @export
#[savvy]
impl Person {
    fn new() -> Self {
        Self {
            name: "".to_string(),
        }
    }
}

New Features

  • A struct marked with #[savvy] can be used as the return type of the
    associated function. In conjunction with the change in v0.3.0, now a
    user-defined struct can be used more flexibly than before. Please refer to
    the "Struct" section of the guide
  • An experimental support on complex is added under compex feature flag.
    ComplexSexp and OwnedComplexSexp are the corresponding Rust types.
  • OwnedIntegerSexp and etc now have set_na(i) method for shorthand of
    set_elt(i, T::na()). This is particularly useful for OwnedLogicalSexp
    because its setter interface set_elt() only accepts bool and no missing
    values.

Fixed bugs

  • An expert-only method new_without_init() now skips initialization as
    intended.

Download savvy-cli 0.4.0

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