devfeatures

package
v1.20.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2026 License: MIT Imports: 1 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// DeployV2DisputeGamesFlag enables deployment of V2 dispute game contracts.
	DeployV2DisputeGamesFlag = common.HexToHash("0x0000000000000000000000000000000000000000000000000000000000000100")

	// ZKDisputeGameFlag enables the ZK dispute game system.
	// TODO(#19432): Use this flag in the OPCM/OPD integration pipeline.
	ZKDisputeGameFlag = common.HexToHash("0x0000000000000000000000000000000000000000000000000000000001000000")

	// SuperRootGamesMigrationFlag enables the super root games migration path in OPCM upgrade.
	SuperRootGamesMigrationFlag = common.HexToHash("0x0000000000000000000000000000000000000000000000000000000010000000")

	// BridgeHookFlag enables bridge hook configuration on OptimismPortal2.
	BridgeHookFlag = common.HexToHash("0x0000000000000000000000000000000000000000000000000000000100000000")

	// OPPrivateFlag enables OP Private.
	OPPrivateFlag = common.HexToHash("0x0000000000000000000000000000000000000000000000000000001000000000")
)

Development feature flag constants.

IMPORTANT: each value here MUST be byte-for-byte identical to the matching constant in packages/contracts-bedrock/src/libraries/DevFeatures.sol. These values are independent literals. No compile-time check keeps them in sync. A mismatch silently diverges Go and Solidity behavior.

When adding a dev feature, update: - packages/contracts-bedrock/scripts/libraries/Config.sol - packages/contracts-bedrock/test/setup/FeatureFlags.sol - .circleci/continue/main.yml (&features_matrix)

Use packages/contracts-bedrock/src/libraries/DevFeatures.sol as the full checklist.

Functions

func EnableDevFeature

func EnableDevFeature(bitmap, flag common.Hash) common.Hash

EnableDevFeature sets a specific development feature flag in a feature bitmap.

func IsDevFeatureEnabled

func IsDevFeatureEnabled(bitmap, flag common.Hash) bool

IsDevFeatureEnabled checks if a specific development feature is enabled in a feature bitmap. It performs a bitwise AND between the bitmap and flag to determine if the feature is set. This follows the same pattern as the Solidity DevFeatures library.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL