Struct Mir

Source
pub struct Mir {
Show 13 fields pub branches: IndexVec<BranchId, AttributeNode<BranchDeclaration>>, pub nets: IndexVec<NetId, AttributeNode<Net>>, pub ports: IndexVec<PortId, Port>, pub disciplines: IndexVec<DisciplineId, AttributeNode<Discipline>>, pub modules: IndexVec<ModuleId, AttributeNode<Module>>, pub parameters: IndexVec<ParameterId, AttributeNode<Parameter>>, pub variables: IndexVec<VariableId, AttributeNode<Variable>>, pub natures: IndexVec<NatureId, AttributeNode<Nature>>, pub attributes: IndexVec<AttributeId, Attribute>, pub real_expressions: IndexVec<RealExpressionId, Node<RealExpression>>, pub integer_expressions: IndexVec<IntegerExpressionId, Node<IntegerExpression>>, pub string_expressions: IndexVec<StringExpressionId, Node<StringExpression>>, pub statements: IndexVec<StatementId, Statement>,
}

Fields§

§branches: IndexVec<BranchId, AttributeNode<BranchDeclaration>>§nets: IndexVec<NetId, AttributeNode<Net>>§ports: IndexVec<PortId, Port>§disciplines: IndexVec<DisciplineId, AttributeNode<Discipline>>§modules: IndexVec<ModuleId, AttributeNode<Module>>§parameters: IndexVec<ParameterId, AttributeNode<Parameter>>§variables: IndexVec<VariableId, AttributeNode<Variable>>§natures: IndexVec<NatureId, AttributeNode<Nature>>§attributes: IndexVec<AttributeId, Attribute>§real_expressions: IndexVec<RealExpressionId, Node<RealExpression>>§integer_expressions: IndexVec<IntegerExpressionId, Node<IntegerExpression>>§string_expressions: IndexVec<StringExpressionId, Node<StringExpression>>§statements: IndexVec<StatementId, Statement>

Implementations§

Source§

impl Mir

Source

pub fn map_real_expr( &mut self, expr: RealExpressionId, variables_to_replace: &FxHashMap<VariableId, VariableId>, ) -> Option<RealExpressionId>

Source

pub fn map_int_expr( &mut self, expr: IntegerExpressionId, variables_to_replace: &FxHashMap<VariableId, VariableId>, ) -> Option<IntegerExpressionId>

Source

pub fn map_str_expr( &mut self, expr: StringExpressionId, variables_to_replace: &FxHashMap<VariableId, VariableId>, ) -> Option<StringExpressionId>

Source§

impl Mir

Source

pub fn track_expression( &self, expr: ExpressionId, dependency_handler: &mut impl DependencyHandler, )

Source

pub fn track_real_expression( &self, expr: RealExpressionId, dependency_handler: &mut impl DependencyHandler, )

Source

pub fn track_integer_expression( &self, expr: IntegerExpressionId, dependency_handler: &mut impl DependencyHandler, )

Source

pub fn track_string_expression( &self, expr: StringExpressionId, dependency_handler: &mut impl DependencyHandler, )

Source§

impl Mir

Source

pub fn declare_partial_derivative_variable( &mut self, variable: VariableId, derive_by: Unknown, ) -> VariableId

Trait Implementations§

Source§

impl Index<AttributeId> for Mir

Source§

type Output = Attribute

The returned type after indexing.
Source§

fn index(&self, index: AttributeId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<BranchId> for Mir

Source§

type Output = AttributeNode<BranchDeclaration>

The returned type after indexing.
Source§

fn index(&self, index: BranchId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<DisciplineId> for Mir

Source§

type Output = AttributeNode<Discipline>

The returned type after indexing.
Source§

fn index(&self, index: DisciplineId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<AttributeId>> for Mir

Source§

type Output = IndexSlice<AttributeId, [Attribute]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<AttributeId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<BranchId>> for Mir

Source§

type Output = IndexSlice<BranchId, [AttributeNode<BranchDeclaration>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<BranchId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<DisciplineId>> for Mir

Source§

type Output = IndexSlice<DisciplineId, [AttributeNode<Discipline>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<DisciplineId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<IntegerExpressionId>> for Mir

Source§

type Output = IndexSlice<IntegerExpressionId, [Node<IntegerExpression>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<IntegerExpressionId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<ModuleId>> for Mir

Source§

type Output = IndexSlice<ModuleId, [AttributeNode<Module>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<ModuleId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<NatureId>> for Mir

Source§

type Output = IndexSlice<NatureId, [AttributeNode<Nature>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<NatureId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<NetId>> for Mir

Source§

type Output = IndexSlice<NetId, [AttributeNode<Net>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<NetId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<ParameterId>> for Mir

Source§

type Output = IndexSlice<ParameterId, [AttributeNode<Parameter>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<ParameterId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<PortId>> for Mir

Source§

type Output = IndexSlice<PortId, [Port]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<PortId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<RealExpressionId>> for Mir

Source§

type Output = IndexSlice<RealExpressionId, [Node<RealExpression>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<RealExpressionId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<StatementId>> for Mir

Source§

type Output = IndexSlice<StatementId, [Statement]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<StatementId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<StringExpressionId>> for Mir

Source§

type Output = IndexSlice<StringExpressionId, [Node<StringExpression>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<StringExpressionId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IdRange<VariableId>> for Mir

Source§

type Output = IndexSlice<VariableId, [AttributeNode<Variable>]>

The returned type after indexing.
Source§

fn index(&self, range: IdRange<VariableId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<IntegerExpressionId> for Mir

Source§

type Output = Node<IntegerExpression>

The returned type after indexing.
Source§

fn index(&self, index: IntegerExpressionId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<ModuleId> for Mir

Source§

type Output = AttributeNode<Module>

The returned type after indexing.
Source§

fn index(&self, index: ModuleId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<NatureId> for Mir

Source§

type Output = AttributeNode<Nature>

The returned type after indexing.
Source§

fn index(&self, index: NatureId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<NetId> for Mir

Source§

type Output = AttributeNode<Net>

The returned type after indexing.
Source§

fn index(&self, index: NetId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<ParameterId> for Mir

Source§

type Output = AttributeNode<Parameter>

The returned type after indexing.
Source§

fn index(&self, index: ParameterId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<PortId> for Mir

Source§

type Output = Port

The returned type after indexing.
Source§

fn index(&self, index: PortId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<AttributeId>> for Mir

Source§

type Output = IndexSlice<AttributeId, [Attribute]>

The returned type after indexing.
Source§

fn index(&self, range: Range<AttributeId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<BranchId>> for Mir

Source§

type Output = IndexSlice<BranchId, [AttributeNode<BranchDeclaration>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<BranchId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<DisciplineId>> for Mir

Source§

type Output = IndexSlice<DisciplineId, [AttributeNode<Discipline>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<DisciplineId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<IntegerExpressionId>> for Mir

Source§

type Output = IndexSlice<IntegerExpressionId, [Node<IntegerExpression>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<IntegerExpressionId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<ModuleId>> for Mir

Source§

type Output = IndexSlice<ModuleId, [AttributeNode<Module>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<ModuleId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<NatureId>> for Mir

Source§

type Output = IndexSlice<NatureId, [AttributeNode<Nature>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<NatureId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<NetId>> for Mir

Source§

type Output = IndexSlice<NetId, [AttributeNode<Net>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<NetId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<ParameterId>> for Mir

Source§

type Output = IndexSlice<ParameterId, [AttributeNode<Parameter>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<ParameterId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<PortId>> for Mir

Source§

type Output = IndexSlice<PortId, [Port]>

The returned type after indexing.
Source§

fn index(&self, range: Range<PortId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<RealExpressionId>> for Mir

Source§

type Output = IndexSlice<RealExpressionId, [Node<RealExpression>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<RealExpressionId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<StatementId>> for Mir

Source§

type Output = IndexSlice<StatementId, [Statement]>

The returned type after indexing.
Source§

fn index(&self, range: Range<StatementId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<StringExpressionId>> for Mir

Source§

type Output = IndexSlice<StringExpressionId, [Node<StringExpression>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<StringExpressionId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<Range<VariableId>> for Mir

Source§

type Output = IndexSlice<VariableId, [AttributeNode<Variable>]>

The returned type after indexing.
Source§

fn index(&self, range: Range<VariableId>) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<RealExpressionId> for Mir

Source§

type Output = Node<RealExpression>

The returned type after indexing.
Source§

fn index(&self, index: RealExpressionId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<StatementId> for Mir

Source§

type Output = Statement

The returned type after indexing.
Source§

fn index(&self, index: StatementId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<StringExpressionId> for Mir

Source§

type Output = Node<StringExpression>

The returned type after indexing.
Source§

fn index(&self, index: StringExpressionId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl Index<VariableId> for Mir

Source§

type Output = AttributeNode<Variable>

The returned type after indexing.
Source§

fn index(&self, index: VariableId) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
Source§

impl IndexMut<AttributeId> for Mir

Source§

fn index_mut(&mut self, index: AttributeId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<BranchId> for Mir

Source§

fn index_mut(&mut self, index: BranchId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<DisciplineId> for Mir

Source§

fn index_mut(&mut self, index: DisciplineId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<AttributeId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<AttributeId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<BranchId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<BranchId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<DisciplineId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<DisciplineId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<IntegerExpressionId>> for Mir

Source§

fn index_mut( &mut self, range: IdRange<IntegerExpressionId>, ) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<ModuleId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<ModuleId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<NatureId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<NatureId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<NetId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<NetId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<ParameterId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<ParameterId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<PortId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<PortId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<RealExpressionId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<RealExpressionId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<StatementId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<StatementId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<StringExpressionId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<StringExpressionId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IdRange<VariableId>> for Mir

Source§

fn index_mut(&mut self, range: IdRange<VariableId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<IntegerExpressionId> for Mir

Source§

fn index_mut(&mut self, index: IntegerExpressionId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<ModuleId> for Mir

Source§

fn index_mut(&mut self, index: ModuleId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<NatureId> for Mir

Source§

fn index_mut(&mut self, index: NatureId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<NetId> for Mir

Source§

fn index_mut(&mut self, index: NetId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<ParameterId> for Mir

Source§

fn index_mut(&mut self, index: ParameterId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<PortId> for Mir

Source§

fn index_mut(&mut self, index: PortId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<AttributeId>> for Mir

Source§

fn index_mut(&mut self, range: Range<AttributeId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<BranchId>> for Mir

Source§

fn index_mut(&mut self, range: Range<BranchId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<DisciplineId>> for Mir

Source§

fn index_mut(&mut self, range: Range<DisciplineId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<IntegerExpressionId>> for Mir

Source§

fn index_mut(&mut self, range: Range<IntegerExpressionId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<ModuleId>> for Mir

Source§

fn index_mut(&mut self, range: Range<ModuleId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<NatureId>> for Mir

Source§

fn index_mut(&mut self, range: Range<NatureId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<NetId>> for Mir

Source§

fn index_mut(&mut self, range: Range<NetId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<ParameterId>> for Mir

Source§

fn index_mut(&mut self, range: Range<ParameterId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<PortId>> for Mir

Source§

fn index_mut(&mut self, range: Range<PortId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<RealExpressionId>> for Mir

Source§

fn index_mut(&mut self, range: Range<RealExpressionId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<StatementId>> for Mir

Source§

fn index_mut(&mut self, range: Range<StatementId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<StringExpressionId>> for Mir

Source§

fn index_mut(&mut self, range: Range<StringExpressionId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<Range<VariableId>> for Mir

Source§

fn index_mut(&mut self, range: Range<VariableId>) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<RealExpressionId> for Mir

Source§

fn index_mut(&mut self, index: RealExpressionId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<StatementId> for Mir

Source§

fn index_mut(&mut self, index: StatementId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<StringExpressionId> for Mir

Source§

fn index_mut(&mut self, index: StringExpressionId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more
Source§

impl IndexMut<VariableId> for Mir

Source§

fn index_mut(&mut self, index: VariableId) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more

Auto Trait Implementations§

§

impl Freeze for Mir

§

impl RefUnwindSafe for Mir

§

impl Send for Mir

§

impl !Sync for Mir

§

impl Unpin for Mir

§

impl UnwindSafe for Mir

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.