smartstring VS api-guidelines

Compare smartstring vs api-guidelines and see what are their differences.

InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
smartstring api-guidelines
7 32
482 1,203
- 0.6%
0.0 3.3
8 months ago about 2 months ago
Rust
Mozilla Public License 2.0 Apache License 2.0
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

smartstring

Posts with mentions or reviews of smartstring. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2022-08-14.
  • Does using "String" instead of "&str" a lot results in unoptimised code?
    3 projects | /r/rust | 14 Aug 2022
    Your use case sounds like it will involve a lot of small strings that use a subset of UTF-8. If you’re concerned about performance, you could look into something like smartstring. Sixbit also looks interesting, but it looks like it won’t give you any more characters and it’d probably require additional computation to do the conversion (and they’d have to be converted back out).
  • Rust Is Hard, Or: The Misery of Mainstream Programming
    15 projects | news.ycombinator.com | 2 Jun 2022
    > If you have a long-running async function, then pass parameters by value! If you have a polymorphic async function, then return your result in a Box.

    I've taken to making heavy use of the smallvec and smartstring crates for this. Most lists and strings are small in practice. Using smallvec / smartstring lets you keep most clone() calls allocation-free. This in turn lets you use owned objects, which are easier to reason about - for you and the borrow checker. And you keep a lot of the performance of just passing around references.

    I tried to use async rust a couple of years ago, and fell on my face in the process. Most of my rust at the moment is designed to compile to wasm - and then I'm leaning on nodejs for networking and IO. Writing async networked code is oh so much easier to reason about in javascript. When GAT, TAIT and some other language features to fix async land I'll muster up the courage to make another attempt. But rust's progress at fixing these problems feels painfully slow.

    https://crates.io/crates/smallvec / https://crates.io/crates/smartstring

  • GitHub - epage/string-benchmarks-rs: Comparison of Rust string types
    3 projects | /r/rust | 25 Mar 2022
    Just to point out, smartstring no longer assumes String memory layout. From the changelog:
  • Why is str not just [char]?
    2 projects | /r/rust | 25 Oct 2021
    There's some really good crates that implement SSO floating around - eg, SmartString. But I agree - its a pity they're needed. Swift built this into the core string type in the language. I think that was the right call.
  • Announcing `compact_str`! A super memory efficient immutable string that is transparently stored on the stack, when possible
    5 projects | /r/rust | 19 Sep 2021
    Comparatively: * SmolStr can inline up to 22 bytes but does not adjust down for 32-bit architectures, meaning it's potentially wasting memory on 32-bit archs. Similarly though it's immutable and Clone is O(1) * SmartString can inline up to 23 bytes, but it's mutable and Clone is O(n). Also this crate makes assumptions about the memory layout of a String, which in theory should be fine, but is a slight caveat.
  • Version 0.19.15 released.
    1 project | /r/Rhai | 31 Mar 2021
    SmartString is used to store identifiers (which tends to be short, fewer than 23 characters, and ASCII-based) because they can usually be stored inline. Map keys now also use SmartString.
  • Speed of Rust vs. C
    17 projects | news.ycombinator.com | 12 Mar 2021
    I’ve been using smartstrings, which is both excellent and maintained. https://github.com/bodil/smartstring

api-guidelines

Posts with mentions or reviews of api-guidelines. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-12-11.
  • Best practices for designing traits in public crates?
    3 projects | /r/rust | 11 Dec 2023
  • Functional Options Pattern in Go and Rust
    2 projects | /r/learnrust | 3 Jun 2023
    Just wanting to let this here for some further input: - https://rust-lang.github.io/api-guidelines/ - https://rust-unofficial.github.io/patterns/ - https://deterministic.space/elegant-apis-in-rust.html
  • Hey Rustaceans! Got a question? Ask here (15/2023)!
    15 projects | /r/rust | 10 Apr 2023
    The API guidelines will help you write nice APIs. Clippy will usually at least find some things, try running with -Wclippy::pedantic for a lot more messages. Also you can ask mentors for specific guidance. Hope that helps.
  • Naming traits
    1 project | /r/learnrust | 31 Mar 2023
    There has been some previous discussion on this here: https://github.com/rust-lang/api-guidelines/discussions/28
  • What is the proper guidance on using generics as parameters for an API
    1 project | /r/rust | 30 Mar 2023
    I'm currently writing an API and using the API guidelines book. On the Flexibility page, there's a section on using generics as function parameters to minimize assumptions. The issue that I'm having is that the only example it gives is std::fs::File::open. Specifically, I want to know what is the "standard" way to use generics as parameters?
  • Prefixes in name and Reexports
    1 project | /r/rust | 12 Mar 2023
    I search up in the rust-api-guideline, but no luck finding something like this. There used to be an Organization according to this thread, but upon digging the repo commits, it was deleted by this commit. "We can reintroduce this section if we come up with a way to give firmer advice here."
  • What are some good practices when writing rust?
    2 projects | /r/rust | 28 Feb 2023
    public api of a library should follow Rust API Guidelines.
  • astro-float 0.6.6 arbitrary precision floating point library update
    2 projects | /r/rust | 23 Feb 2023
    API was made compliant with Rust API Guidelines.
  • Picking Up Rust Before C With My Goals In Mind?
    9 projects | /r/rust | 5 Feb 2023
    Finally, there's also the Little Book of Rust Books where you could look for tutorial materials or things like like Rust Design Patterns, Rust API Guidelines, and The Rust Performance Book. (See also rust-learning)
  • Learning rust
    4 projects | /r/rust | 17 Dec 2022
    Rust API Guidelines: If you're planning on building libraries or APIs in Rust, these guidelines provide recommendations for designing and presenting APIs in the language. They're written by the Rust library team, based on their experience building the Rust standard library and other crates in the ecosystem.

What are some alternatives?

When comparing smartstring and api-guidelines you can also consider the following projects:

smol_str

wasm-bindgen - Facilitating high-level interactions between Wasm modules and JavaScript

compact_str - A memory efficient string type that can store up to 24* bytes on the stack

patterns - A catalogue of Rust design patterns, anti-patterns and idioms

min-sized-rust - 🦀 How to minimize Rust binary size 📦

too-many-lists - Learn Rust by writing Entirely Too Many linked lists

libskry_r - Lucky imaging library

idiomatic-rust - 🦀 A peer-reviewed collection of articles/talks/repos which teach concise, idiomatic Rust.

bitter - Extract bits from a byte slice

rust - Empowering everyone to build reliable and efficient software.

redgrep - ♥ Janusz Brzozowski

gdnative - Rust bindings for Godot 3