diff options
author | Philip Herron <philip.herron@embecosm.com> | 2021-01-29 17:15:14 +0000 |
---|---|---|
committer | Philip Herron <herron.philip@googlemail.com> | 2021-02-03 10:38:13 +0000 |
commit | 419677348e1c1e6092e74f55b3a7326a595d6114 (patch) | |
tree | ff230e7c4ae08febd95e2f77d8313cf68da23db4 /gcc/rust/backend/rust-compile-expr.h | |
parent | 36ac7b79717b580a9adbbb07383d17fe6d63be2f (diff) | |
download | gcc-419677348e1c1e6092e74f55b3a7326a595d6114.zip gcc-419677348e1c1e6092e74f55b3a7326a595d6114.tar.gz gcc-419677348e1c1e6092e74f55b3a7326a595d6114.tar.bz2 |
Add support for impl blocks for functions and constants.
This is the building block in adding support for methods and the self
keyword.
Fixes: #111
Diffstat (limited to 'gcc/rust/backend/rust-compile-expr.h')
-rw-r--r-- | gcc/rust/backend/rust-compile-expr.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/rust/backend/rust-compile-expr.h b/gcc/rust/backend/rust-compile-expr.h index 81d7786..ccff51a 100644 --- a/gcc/rust/backend/rust-compile-expr.h +++ b/gcc/rust/backend/rust-compile-expr.h @@ -481,6 +481,11 @@ public: expr.get_locus ()); } + void visit (HIR::PathInExpression &expr) + { + translated = ResolvePathRef::Compile (&expr, ctx); + } + private: CompileExpr (Context *ctx) : HIRCompileBase (ctx), translated (nullptr) {} |