diff options
Diffstat (limited to 'flowgraph/storage.h')
-rw-r--r-- | flowgraph/storage.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/flowgraph/storage.h b/flowgraph/storage.h index 28aae1e..fd3c085 100644 --- a/flowgraph/storage.h +++ b/flowgraph/storage.h @@ -37,15 +37,6 @@ namespace FlowGraph { std::string m_name; }; - class LocalStorage : public Storage - { - public: - LocalStorage(const std::string& name): m_name(name) {} - const std::string& name() const { return m_name; } - private: - std::string m_name; - }; - // Provide a context for local temporaries name generation class LocalScope { @@ -56,6 +47,15 @@ namespace FlowGraph { size_t m_index{ 0 }; }; + class LocalStorage : public Storage + { + public: + LocalStorage(LocalScope& scope, const std::string& name): m_name(name) {} + const std::string& name() const { return m_name; } + private: + std::string m_name; + }; + // intermediate results, anonymous values // use generated name class TemporaryStorage : public Storage |