NEURON
state_discontinuity_visitor.hpp
Go to the documentation of this file.
1 /*
2  * Copyright 2025 EPFL.
3  * See the top-level LICENSE file for details.
4  *
5  * SPDX-License-Identifier: Apache-2.0
6  */
7 
8 #pragma once
9 
10 /**
11  * \file
12  * \brief \copybrief nmodl::visitor::StateDiscontinuityVisitor
13  */
14 
15 #include "symtab/decl.hpp"
16 #include "visitors/ast_visitor.hpp"
17 #include <string>
18 #include <unordered_set>
19 
20 namespace nmodl {
21 namespace visitor {
22 
23 /**
24  * \addtogroup visitor_classes
25  * \{
26  */
27 
28 /**
29  * \class StateDiscontinuityVisitor
30  * \brief Visitor used for replacing literal calls to `state_discontinuity` in a NET_RECEIVE block
31  */
33  private:
34  /// true if we are visiting a NET_RECEIVE block
35  bool in_net_receive_block = false;
36 
37  public:
40 };
41 
42 /** \} */ // end of visitor_classes
43 
44 } // namespace visitor
45 } // namespace nmodl
Concrete visitor for all AST classes.
Represents block encapsulating list of statements.
Concrete visitor for all AST classes.
Definition: ast_visitor.hpp:37
Visitor used for replacing literal calls to state_discontinuity in a NET_RECEIVE block.
void visit_statement_block(ast::StatementBlock &node) override
visit node of type ast::StatementBlock
void visit_net_receive_block(ast::NetReceiveBlock &node) override
visit node of type ast::NetReceiveBlock
bool in_net_receive_block
true if we are visiting a NET_RECEIVE block
encapsulates code generation backend implementations
Definition: ast_common.hpp:26
static Node * node(Object *)
Definition: netcvode.cpp:291
Forward declarations of symbols in namespace nmodl::symtab.