aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/backend/rust-compile-resolve-path.h
diff options
context:
space:
mode:
authorPhilip Herron <philip.herron@embecosm.com>2021-02-25 15:21:34 +0000
committerPhilip Herron <herron.philip@googlemail.com>2021-03-01 10:35:07 +0000
commitec9ead44a40ee68de7fc39e32a47662c44281deb (patch)
tree72af294bf6f54e4becebb22a860823f12aed062c /gcc/rust/backend/rust-compile-resolve-path.h
parent9af2ae0ff91535da104db0d3828d863770439fad (diff)
downloadgcc-ec9ead44a40ee68de7fc39e32a47662c44281deb.zip
gcc-ec9ead44a40ee68de7fc39e32a47662c44281deb.tar.gz
gcc-ec9ead44a40ee68de7fc39e32a47662c44281deb.tar.bz2
Adds the same support from generic structs in #235 onto tuple structs
Type binding still not supported here but the same generic support is added to tuples. Fixes #236
Diffstat (limited to 'gcc/rust/backend/rust-compile-resolve-path.h')
-rw-r--r--gcc/rust/backend/rust-compile-resolve-path.h20
1 files changed, 1 insertions, 19 deletions
diff --git a/gcc/rust/backend/rust-compile-resolve-path.h b/gcc/rust/backend/rust-compile-resolve-path.h
index 2f3cb68..ae469e6 100644
--- a/gcc/rust/backend/rust-compile-resolve-path.h
+++ b/gcc/rust/backend/rust-compile-resolve-path.h
@@ -35,7 +35,7 @@ public:
return resolver.resolved;
}
- void visit (HIR::PathInExpression &expr);
+ void visit (HIR::PathInExpression &expr) override;
private:
ResolvePathRef (Context *ctx) : HIRCompileBase (ctx), resolved (nullptr) {}
@@ -43,24 +43,6 @@ private:
Bexpression *resolved;
};
-class ResolvePathType : public HIRCompileBase
-{
-public:
- static Btype *Compile (HIR::Expr *expr, Context *ctx)
- {
- ResolvePathType resolver (ctx);
- expr->accept_vis (resolver);
- return resolver.resolved;
- }
-
- void visit (HIR::PathInExpression &expr);
-
-private:
- ResolvePathType (Context *ctx) : HIRCompileBase (ctx), resolved (nullptr) {}
-
- Btype *resolved;
-};
-
} // namespace Compile
} // namespace Rust