bevy/tools/build-templated-pages/Cargo.toml
Tristan Guichaoua 1cded6ac60
Use immutable key for HashMap and HashSet (#12086)
# Objective

Memory usage optimisation

## Solution

`HashMap` and `HashSet`'s keys are immutable. So using mutable types
like `String`, `Vec<T>`, or `PathBuf` as a key is a waste of memory:
they have an extra `usize` for their capacity and may have spare
capacity.
This PR replaces these types by their immutable equivalents `Box<str>`,
`Box<[T]>`, and `Box<Path>`.

For more context, I recommend watching the [Use Arc Instead of
Vec](https://www.youtube.com/watch?v=A4cKi7PTJSs) video.

---------

Co-authored-by: James Liu <contact@jamessliu.com>
2024-02-26 16:27:40 +00:00

17 lines
445 B
TOML

[package]
name = "build-templated-pages"
version = "0.14.0-dev"
edition = "2021"
description = "handle templated pages in Bevy repository"
publish = false
license = "MIT OR Apache-2.0"
[lints]
workspace = true
[dependencies]
toml_edit = { version = "0.22", default-features = false, features = ["parse"] }
tera = "1.15"
serde = { version = "1.0", features = ["derive"] }
bitflags = "2.3"
hashbrown = { version = "0.14", features = ["serde"] }