summaryrefslogtreecommitdiffhomepage
path: root/flowgraph/node.h
diff options
context:
space:
mode:
authorRoland Reichwein <mail@reichwein.it>2020-11-17 12:38:40 +0100
committerRoland Reichwein <mail@reichwein.it>2020-11-17 12:38:40 +0100
commit927eb99e75325164a541c2638e1e607294019381 (patch)
tree5b5476456f0f957fc7492465ff08ace54e1a9e48 /flowgraph/node.h
parentc9cb051fae190acfc36813e4a23759fb9b9c3df3 (diff)
Complete hierarchical evaluation (unittest and systemtest fixed)
Diffstat (limited to 'flowgraph/node.h')
-rw-r--r--flowgraph/node.h18
1 files changed, 11 insertions, 7 deletions
diff --git a/flowgraph/node.h b/flowgraph/node.h
index 5ea194d..6a3ef14 100644
--- a/flowgraph/node.h
+++ b/flowgraph/node.h
@@ -5,6 +5,8 @@
#include "data.h"
#include "storage.h"
+#include <memory>
+
namespace FlowGraph {
// Node in Graph: Building block of the graph
@@ -46,9 +48,9 @@ namespace FlowGraph {
};
Data MakeConstantInt(int i);
- Data MakeLocalPointer(FlowGraph::LocalScope& scope, const std::string& name);
- Data MakeLocalSize(FlowGraph::LocalScope& scope, const std::string& name);
- Data MakeTemporaryInt(LocalScope& scope);
+ Data MakeLocalPointer(std::shared_ptr<FlowGraph::LocalScope> scope, const std::string& name);
+ Data MakeLocalSize(std::shared_ptr<FlowGraph::LocalScope> scope, const std::string& name);
+ Data MakeTemporaryInt(std::shared_ptr<LocalScope> scope);
class MemCopy: public Node
{
@@ -176,17 +178,19 @@ namespace FlowGraph {
class CreateScopeOp: public Node
{
public:
- CreateScopeOp() {}
- LocalScope& scope();
+ CreateScopeOp();
+ std::shared_ptr<LocalScope> scope();
private:
- LocalScope m_scope;
+ std::shared_ptr<LocalScope> m_scope;
};
// Close current scope, closing stack frame
class DestroyScopeOp: public Node
{
public:
- DestroyScopeOp(LocalScope& scope) {}
+ DestroyScopeOp(std::shared_ptr<LocalScope> scope);
+ private:
+ std::shared_ptr<LocalScope> m_scope;
};
} // namespace FlowGraph