qubit_codec_binary/codec/non_strict.rs
1// =============================================================================
2// Copyright (c) 2026 Haixing Hu.
3//
4// SPDX-License-Identifier: Apache-2.0
5//
6// Licensed under the Apache License, Version 2.0.
7// =============================================================================
8
9use super::Leb128DecodePolicy;
10
11/// Marker type selecting non-strict decoding.
12#[derive(Clone, Copy, Debug, Default, Eq, PartialEq)]
13pub struct NonStrict;
14
15impl super::sealed::Sealed for NonStrict {}
16
17impl Leb128DecodePolicy for NonStrict {
18 /// Whether this policy accepts non-canonical encodings.
19 const STRICT: bool = false;
20}