From c15006c15505ae785eb5447c055b8f9379e7fcde Mon Sep 17 00:00:00 2001 From: John Hodge Date: Fri, 3 Apr 2015 22:57:27 +0800 Subject: Added partial support for #[derive()] - Supports Debug on struct, and assumes compiling in libcore (for now) --- src/ast/path.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/ast/path.hpp') diff --git a/src/ast/path.hpp b/src/ast/path.hpp index a2ca316b..390271fe 100644 --- a/src/ast/path.hpp +++ b/src/ast/path.hpp @@ -180,7 +180,10 @@ public: struct TagLocal {}; Path(TagLocal, ::std::string name): m_class(LOCAL), - m_nodes({PathNode(name, {})}) + m_nodes({PathNode( ::std::move(name), {} )}) + {} + Path(::std::string name): + Path(TagLocal(), ::std::move(name)) {} struct TagSuper {}; Path(TagSuper): -- cgit v1.2.3