summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2016-05-06 10:37:20 +0800
committerJohn Hodge <tpg@mutabah.net>2016-05-06 10:37:20 +0800
commit3081e4762069a8ba401f77bee4951061b1e9589a (patch)
tree7517cb13bf2047246ca931a970a9ee3110b63f62 /src
parent04fb5517cfadf33ac3b753a714e0338810ba8fb1 (diff)
downloadmrust-3081e4762069a8ba401f77bee4951061b1e9589a.tar.gz
Resolve/absolute - Passing for libcore
Diffstat (limited to 'src')
-rw-r--r--src/resolve/absolute.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/resolve/absolute.cpp b/src/resolve/absolute.cpp
index ad75a206..b3722f29 100644
--- a/src/resolve/absolute.cpp
+++ b/src/resolve/absolute.cpp
@@ -165,6 +165,7 @@ struct Context
enum class LookupMode {
+ //Namespace,
Type,
Constant,
Pattern,
@@ -302,6 +303,13 @@ struct Context
return rv;
}
+ // Look up primitive types
+ auto ct = coretype_fromstring(name);
+ if( ct != CORETYPE_INVAL )
+ {
+ return ::AST::Path( ::AST::Path::TagUfcs(), TypeRef(Span(), ct), ::std::vector< ::AST::PathNode>() );
+ }
+
return AST::Path();
}