Skip to content

Commit

Permalink
feat: enable PRAGUE on bsc
Browse files Browse the repository at this point in the history
  • Loading branch information
j75689 committed Dec 26, 2024
1 parent d66170e commit d24ce21
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 4 additions & 1 deletion crates/precompile/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ impl Precompiles {
PrecompileSpecId::HERTZ => Self::hertz(),
PrecompileSpecId::FEYNMAN => Self::feynman(),
PrecompileSpecId::CANCUN => Self::cancun(),
PrecompileSpecId::PRAGUE => Self::prague(),
PrecompileSpecId::HABER => Self::haber(),
PrecompileSpecId::PRAGUE => Self::prague(),
PrecompileSpecId::LATEST => Self::latest(),
}
}
Expand Down Expand Up @@ -308,6 +308,9 @@ impl Precompiles {
pub fn prague() -> &'static Self {
static INSTANCE: OnceBox<Precompiles> = OnceBox::new();
INSTANCE.get_or_init(|| {
#[cfg(feature = "bsc")]
let precompiles = Self::haber().clone();
#[cfg(not(feature = "bsc"))]
let precompiles = Self::cancun().clone();

// Don't include BLS12-381 precompiles in no_std builds.
Expand Down
4 changes: 2 additions & 2 deletions crates/primitives/src/specification.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,14 +118,14 @@ pub enum SpecId {
HABER = 30, // Haber timestamp(1718863500)
HABER_FIX = 31, // HaberFix timestamp(1720591588)
BOHR = 32, // Bohr timestamp(1720591588)
PRAGUE = 33, // Prague TBD

/// Not enabled in bsc
DAO_FORK = 100,
ARROW_GLACIER = 101,
GRAY_GLACIER = 102,
MERGE = 103,
PRAGUE = 104,
OSAKA = 106,
OSAKA = 104,
#[default]
LATEST = u8::MAX,
}
Expand Down

0 comments on commit d24ce21

Please sign in to comment.