mirror of
https://github.com/edg-l/rustyman.git
synced 2024-09-19 09:12:20 +00:00
const node new
This commit is contained in:
parent
f05132f0ee
commit
264ef60602
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "rustyman"
|
name = "rustyman"
|
||||||
version = "0.2.3"
|
version = "0.3.0"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
authors = ["Edgar <git@edgarluque.com>"]
|
authors = ["Edgar <git@edgarluque.com>"]
|
||||||
description = "Huffman compression and decompression"
|
description = "Huffman compression and decompression"
|
||||||
|
@ -10,6 +10,7 @@ keywords = ["huffman", "compression", "decompression", "lossless", "huffman-codi
|
||||||
categories = ["compression", "algorithms"]
|
categories = ["compression", "algorithms"]
|
||||||
documentation = "https://docs.rs/rustyman"
|
documentation = "https://docs.rs/rustyman"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
|
rust-version = "1.63.0" # array from_fn
|
||||||
|
|
||||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,7 @@ struct Node {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Node {
|
impl Node {
|
||||||
fn new(index: usize, count: usize) -> Self {
|
const fn new(index: usize, count: usize) -> Self {
|
||||||
Self {
|
Self {
|
||||||
index,
|
index,
|
||||||
count,
|
count,
|
||||||
|
|
Loading…
Reference in a new issue