diff options
author | Marc Poulhiès <dkm@kataplop.net> | 2021-03-08 21:13:02 +0100 |
---|---|---|
committer | Philip Herron <herron.philip@googlemail.com> | 2021-03-27 18:03:34 +0000 |
commit | fabb3894d5fe5c2ca87917fd08b2f0813553532d (patch) | |
tree | c31d037df544c9dbd3adaa1f904ce38620037d3b /gcc/rust/resolve/rust-ast-resolve.cc | |
parent | f9f1f1d7211e555ae7a22b21723ced7610fa5657 (diff) | |
download | gcc-fabb3894d5fe5c2ca87917fd08b2f0813553532d.zip gcc-fabb3894d5fe5c2ca87917fd08b2f0813553532d.tar.gz gcc-fabb3894d5fe5c2ca87917fd08b2f0813553532d.tar.bz2 |
WIP for #252
Removed TyTy::UnitType and TyTy::TypeKind::UNIT.
Replaced by TyTy::TupleType with an empty list of fields.
Added default empty vector for fields in ctor for TyTy::TypeType.
Diffstat (limited to 'gcc/rust/resolve/rust-ast-resolve.cc')
-rw-r--r-- | gcc/rust/resolve/rust-ast-resolve.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/rust/resolve/rust-ast-resolve.cc b/gcc/rust/resolve/rust-ast-resolve.cc index 65750a9..b4ca34f 100644 --- a/gcc/rust/resolve/rust-ast-resolve.cc +++ b/gcc/rust/resolve/rust-ast-resolve.cc @@ -178,7 +178,9 @@ Resolver::generate_builtins () MKBUILTIN_TYPE ("str", builtins, str); // unit type () - TyTy::UnitType *unit_tyty = new TyTy::UnitType (mappings->get_next_hir_id ()); + + TyTy::TupleType *unit_tyty + = new TyTy::TupleType (mappings->get_next_hir_id ()); std::vector<std::unique_ptr<AST::Type> > elems; AST::TupleType *unit_type = new AST::TupleType (std::move (elems), Linemap::predeclared_location ()); |