| 1 | # Changelog |
| 2 | |
| 3 | ## v0.4.2 (2025-05-17) |
| 4 | |
| 5 | * Add support for truncating string arguments (e.g. `%1.3s`) (PR [#15][PR15], thanks to [Samuel Collins (sd-collins)][sd-collins]) |
| 6 | |
| 7 | [PR15]: https://github.com/tjol/sprintf-rs/pull/15 |
| 8 | |
| 9 | ## v0.4.1 (2025-04-30) |
| 10 | |
| 11 | * Update to thiserror 2.0 (PR [#11][PR11], thanks to [Samuel Collins (sd-collins)][sd-collins]) |
| 12 | * Add support for padding strings and chars (e.g. `%10s`) (PR [#13][PR13], thanks to [Samuel Collins (sd-collins)][sd-collins]) |
| 13 | |
| 14 | [PR11]: https://github.com/tjol/sprintf-rs/pull/11 |
| 15 | [PR13]: https://github.com/tjol/sprintf-rs/pull/13 |
| 16 | |
| 17 | ## v0.4.0 (2024-12-05) |
| 18 | |
| 19 | * `FormatElement` now borrows a `&str` instead of owning a `String`, leading to fewer allocations and a significant performance improvement (PR [#10][PR10], thanks to [Samuel Collins (sd-collins)][sd-collins]). |
| 20 | - this is a __breaking API change__ to the lower-level v0.2 API |
| 21 | - the original and primary (v0.1) API is unchanged |
| 22 | |
| 23 | [PR10]: https://github.com/tjol/sprintf-rs/pull/10 |
| 24 | [sd-collins]: https://github.com/sd-collins |
| 25 | |
| 26 | ## v0.3.1 (2024-07-14) |
| 27 | |
| 28 | * pointer types can be formatted with `%p` in the same way as `usize` (PR [#9][PR9], thanks to [Flávio J. Saraiva (flaviojs)][flaviojs]) |
| 29 | |
| 30 | [PR9]: https://github.com/tjol/sprintf-rs/pull/9 |
| 31 | |
| 32 | ## v0.3.0 (2024-05-31) |
| 33 | |
| 34 | * More standard string and character types (PR [#7][PR7], thanks to [Flávio J. Saraiva (flaviojs)][flaviojs]) |
| 35 | * Support `CString` and `&CStr` for `%s`, assuming the're UTF-8 encoded |
| 36 | * Support `u8` and `i8` (ASCII), `u16` (UCS-2) and `u32` (UCS-4) for `%c` |
| 37 | |
| 38 | [PR7]: https://github.com/tjol/sprintf-rs/pull/7 |
| 39 | [flaviojs]: https://github.com/flaviojs |
| 40 | |
| 41 | ## v0.2.1 (2024-02-12) |
| 42 | |
| 43 | * Fix accidental backwards-incompatible API change in v0.2.0 |
| 44 | |
| 45 | ## v0.2.0 (2024-02-12) |
| 46 | |
| 47 | * Expose the some of the `sprintf::parser` module in the API to allow other to use the `parse_format_string` function (PR [#5][PR5], thanks to [David Alexander Bjerremose (DaBs)][DaBs]) |
| 48 | * `PrintfError` now implements `std::error::Error` |
| 49 | |
| 50 | [PR5]: https://github.com/tjol/sprintf-rs/pull/5 |
| 51 | [DaBs]: https://github.com/DaBs |
| 52 | |
| 53 | ## v0.1.4 (2023-09-10) |
| 54 | |
| 55 | * Fix parsing of `ll` length specifier (PR [#4][PR4], thanks to [Ido Yariv (codido)][codido]) |
| 56 | |
| 57 | [PR4]: https://github.com/tjol/sprintf-rs/pull/4 |
| 58 | [codido]: https://github.com/codido |
| 59 | |
| 60 | ## v0.1.3 (2022-09-23) |
| 61 | |
| 62 | * Fix float rounding: 9.99 should round to 10.0, not 9.0. (Issue [#2][bug2], thanks to [Nicholas Ritchie][NicholasWMRitchie]) |
| 63 | |
| 64 | [bug2]: https://github.com/tjol/sprintf-rs/issues/2 |
| 65 | [NicholasWMRitchie]: https://github.com/NicholasWMRitchie |
| 66 | |
| 67 | ## v0.1.2 (2021-11-06) |
| 68 | |
| 69 | * Fix formatting of large floats (PR [#1][PR1], thanks to [Kuba (pierd)][pierd] |
| 70 | |
| 71 | [PR1]: https://github.com/tjol/sprintf-rs/pull/1 |
| 72 | [pierd]: https://github.com/pierd |
| 73 | |
| 74 | ## v0.1.1 (2021-08-30) |
| 75 | |
| 76 | * Fix bug in padding of fixed-width fields |
| 77 | |
| 78 | ## v0.1.0 (2021-08-24) |
| 79 | |
| 80 | * Initial release |