summaryrefslogtreecommitdiff
path: root/src/ast/provided_module.cpp
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2015-03-31 19:42:05 +0800
committerJohn Hodge <tpg@mutabah.net>2015-03-31 19:42:05 +0800
commit752202c3857b00d0aa53117573d4a931f79ed65d (patch)
treec1884c7206604f778c2b8607febd53489e29a7fd /src/ast/provided_module.cpp
parentf725889aedd5b64141e8f8e9924e4e59f716c225 (diff)
downloadmrust-752202c3857b00d0aa53117573d4a931f79ed65d.tar.gz
Add Copy impls (hacky), and parameter count checking/extending
Diffstat (limited to 'src/ast/provided_module.cpp')
-rw-r--r--src/ast/provided_module.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/ast/provided_module.cpp b/src/ast/provided_module.cpp
index ea323172..bb1da26b 100644
--- a/src/ast/provided_module.cpp
+++ b/src/ast/provided_module.cpp
@@ -10,5 +10,9 @@ void AST_InitProvidedModule()
g_compiler_module.add_struct(true, "str", AST::TypeParams(), ::std::vector<AST::StructItem> {
AST::StructItem("", TypeRef(TypeRef::TagUnsizedArray(), TypeRef(CORETYPE_U8)), false),
});
+
+ AST::Path copy_marker_path({AST::PathNode("marker"),AST::PathNode("Copy")});
+ g_compiler_module.add_impl(AST::Impl(AST::TypeParams(), TypeRef(CORETYPE_F32), copy_marker_path));
+ g_compiler_module.add_impl(AST::Impl(AST::TypeParams(), TypeRef(CORETYPE_F64), copy_marker_path));
}