mirror of
https://github.com/starovoid/rxing.git
synced 2026-07-26 04:12:34 +00:00
change to using once_cell for lazy init
This commit is contained in:
@@ -20,13 +20,11 @@ use crate::{common::BitMatrix, Exceptions};
|
||||
|
||||
use super::{ErrorCorrectionLevel, FormatInformation};
|
||||
|
||||
use lazy_static::lazy_static;
|
||||
use once_cell::sync::Lazy;
|
||||
|
||||
pub type VersionRef = &'static Version;
|
||||
|
||||
lazy_static! {
|
||||
static ref VERSIONS: Vec<Version> = Version::buildVersions();
|
||||
}
|
||||
static VERSIONS: Lazy<Vec<Version>> = Lazy::new(|| Version::buildVersions());
|
||||
|
||||
/**
|
||||
* See ISO 18004:2006 Annex D.
|
||||
|
||||
Reference in New Issue
Block a user