use bitflags::bitflags;
#[cfg(feature = "no_std")]
use std::prelude::v1::*;
#[derive(Debug, Clone, Copy, Eq, PartialEq, Ord, PartialOrd, Hash)]
#[cfg_attr(feature = "metadata", derive(serde::Serialize))]
#[cfg_attr(feature = "metadata", serde(rename_all = "camelCase"))]
#[non_exhaustive]
pub enum FnAccess {
Private,
Public,
}
impl FnAccess {
#[inline(always)]
#[must_use]
pub const fn is_private(self) -> bool {
match self {
Self::Private => true,
Self::Public => false,
}
}
#[inline(always)]
#[must_use]
pub const fn is_public(self) -> bool {
match self {
Self::Private => false,
Self::Public => true,
}
}
}
bitflags! {
pub struct ASTFlags: u8 {
const NONE = 0b_0000_0000;
const CONSTANT = 0b_0000_0001;
const EXPORTED = 0b_0000_0010;
const NEGATED = 0b_0000_0100;
const BREAK = 0b_0000_1000;
}
}