sv_parser_syntaxtree/declarations/
port_declarations.rs1use crate::*;
2
3#[derive(Clone, Debug, PartialEq, Node)]
6pub struct InoutDeclaration {
7 pub nodes: (Keyword, NetPortType, ListOfPortIdentifiers),
8}
9
10#[derive(Clone, Debug, PartialEq, Node)]
11pub enum InputDeclaration {
12 Net(Box<InputDeclarationNet>),
13 Variable(Box<InputDeclarationVariable>),
14}
15
16#[derive(Clone, Debug, PartialEq, Node)]
17pub struct InputDeclarationNet {
18 pub nodes: (Keyword, NetPortType, ListOfPortIdentifiers),
19}
20
21#[derive(Clone, Debug, PartialEq, Node)]
22pub struct InputDeclarationVariable {
23 pub nodes: (Keyword, VariablePortType, ListOfVariableIdentifiers),
24}
25
26#[derive(Clone, Debug, PartialEq, Node)]
27pub enum OutputDeclaration {
28 Net(Box<OutputDeclarationNet>),
29 Variable(Box<OutputDeclarationVariable>),
30}
31
32#[derive(Clone, Debug, PartialEq, Node)]
33pub struct OutputDeclarationNet {
34 pub nodes: (Keyword, NetPortType, ListOfPortIdentifiers),
35}
36
37#[derive(Clone, Debug, PartialEq, Node)]
38pub struct OutputDeclarationVariable {
39 pub nodes: (Keyword, VariablePortType, ListOfVariablePortIdentifiers),
40}
41
42#[derive(Clone, Debug, PartialEq, Node)]
43pub struct InterfacePortDeclaration {
44 pub nodes: (
45 InterfaceIdentifier,
46 Option<(Symbol, ModportIdentifier)>,
47 ListOfInterfaceIdentifiers,
48 ),
49}
50
51#[derive(Clone, Debug, PartialEq, Node)]
52pub struct RefDeclaration {
53 pub nodes: (Keyword, VariablePortType, ListOfVariableIdentifiers),
54}