pub enum TypePolicy {
Gradual,
Strict,
}Expand description
types project policy (docs/typed-mode-spec.md §1). Gradual is the
pre-flip behavior — Unknown unifies with anything, annotations are
optional seasoning, and the strict checks do not run. Strict requires
dialect = brink.
The default is dialect-keyed since the 2026-07-19 “Typing posture
ruled” decision (issue #1127) — see brink_analyzer::resolve_type_policy.
The derived Default (Gradual) exists only so pre-resolution containers
can derive theirs; policy defaulting must never read it directly.
Defined here for the same reason as Dialect, and re-exported by
brink-analyzer.
Variants§
Trait Implementations§
Source§impl Clone for TypePolicy
impl Clone for TypePolicy
Source§fn clone(&self) -> TypePolicy
fn clone(&self) -> TypePolicy
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TypePolicy
Source§impl Debug for TypePolicy
impl Debug for TypePolicy
Source§impl Default for TypePolicy
impl Default for TypePolicy
Source§fn default() -> TypePolicy
fn default() -> TypePolicy
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for TypePolicy
impl<'de> Deserialize<'de> for TypePolicy
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<TypePolicy, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<TypePolicy, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for TypePolicy
Source§impl PartialEq for TypePolicy
impl PartialEq for TypePolicy
Source§impl Serialize for TypePolicy
impl Serialize for TypePolicy
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for TypePolicy
Auto Trait Implementations§
impl Freeze for TypePolicy
impl RefUnwindSafe for TypePolicy
impl Send for TypePolicy
impl Sync for TypePolicy
impl Unpin for TypePolicy
impl UnsafeUnpin for TypePolicy
impl UnwindSafe for TypePolicy
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.