Debian Codegraph @

/

debian rust-sprintf 0.4.2-1debian librust-sprintf-dev debian librust-sprintf+default-dev debian librust-sprintf-0-dev debian librust-sprintf-0+default-dev debian librust-sprintf-0.4-dev debian librust-sprintf-0.4+default-dev debian librust-sprintf-0.4.2-dev debian librust-sprintf-0.4.2+default-dev cargo sprintf 0.4.2 debianjsonmakefilemarkdownrustrust-c-abishelltomlyaml 20 files · 275 symbols
View dependency graph

Depends on

  • dh-cargo (dh-sequence-cargo)
  • cargo, debhelper-compat, librust-thiserror-2+default-dev, libstd-rust-dev, rustc
README (full)

sprintf-rs

a clone of C sprintf in Rust

This crate was created out of a desire to provide C printf-style formatting in a WASM program, where there is no libc.

Note: You're probably better off using standard Rust string formatting instead of this crate unless you specificaly need printf compatibility.

This crate implements a dynamically type-checked function vsprintf and macro sprintf!.

Usage example:

use sprintf::sprintf;
let s = sprintf!("%d + %d = %d\n", 3, 9, 3+9).unwrap();
assert_eq!(s, "3 + 9 = 12\n");

libc is a dev dependency as it is used in the tests to compare results. std is used for some maths functions.

dir .github/
dir debian/
dir src/
dir tests/
file .cargo_vcs_info.json
file .gitignore
file CHANGELOG.md
file COPYING
file Cargo.lock
file Cargo.toml
file Cargo.toml.orig
file README.md