Skip to content

Commit b39ecb9

Browse files
emkwdylanhart
authored andcommitted
Make ulid::Generator::new() const
This allows static generator initialization - #83
1 parent b7f33ce commit b39ecb9

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/generator.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ impl Generator {
2323
///
2424
/// assert!(ulid1 < ulid2);
2525
/// ```
26-
pub fn new() -> Generator {
26+
pub const fn new() -> Generator {
2727
Generator {
2828
previous: Ulid::nil(),
2929
}

0 commit comments

Comments
 (0)