diff options
author | John Hodge <tpg@mutabah.net> | 2016-11-07 08:37:02 +0800 |
---|---|---|
committer | John Hodge <tpg@mutabah.net> | 2016-11-07 08:37:02 +0800 |
commit | 815ae041cff5bf744e41cf7d70c81b156609831c (patch) | |
tree | 2816ec25ffc034744515a0645efc49de71e052b6 /src/mir/from_hir_match.cpp | |
parent | a52f6ddf9a15716fb5b2b23cb0a9242750958547 (diff) | |
download | mrust-815ae041cff5bf744e41cf7d70c81b156609831c.tar.gz |
MIR Gen Match - Fix DTN clone
Diffstat (limited to 'src/mir/from_hir_match.cpp')
-rw-r--r-- | src/mir/from_hir_match.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mir/from_hir_match.cpp b/src/mir/from_hir_match.cpp index 1f3bb7eb..83db3c74 100644 --- a/src/mir/from_hir_match.cpp +++ b/src/mir/from_hir_match.cpp @@ -1634,6 +1634,7 @@ struct DecisionTreeNode DecisionTreeNode( PatternRule::field_path_t field_path ): is_specialisation(false)/*, + // TODO: This is commented out fo a reason, but I don't know why. m_field_path( mv$(field_path) ) // */ {} @@ -1909,6 +1910,7 @@ DecisionTreeNode::Values DecisionTreeNode::clone(const DecisionTreeNode::Values& } DecisionTreeNode DecisionTreeNode::clone() const { DecisionTreeNode rv(m_field_path); + rv.m_field_path = m_field_path; rv.is_specialisation = is_specialisation; rv.m_branches = clone(m_branches); rv.m_default = clone(m_default); |