diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2022-04-26 08:45:21 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-26 08:45:21 +0000 |
commit | d7c5bbe6af7189a95d1e4f2d4171fd8b53e826b3 (patch) | |
tree | 88cf4a3e201420dde427f004471c6898fea54af5 /gcc/rust/backend/rust-compile-resolve-path.cc | |
parent | b74044fb6278e373da607a8f1f5df2193ce27d65 (diff) | |
parent | e69e162462c6fb3d886460d96ce649207b7c9e3f (diff) | |
download | gcc-d7c5bbe6af7189a95d1e4f2d4171fd8b53e826b3.zip gcc-d7c5bbe6af7189a95d1e4f2d4171fd8b53e826b3.tar.gz gcc-d7c5bbe6af7189a95d1e4f2d4171fd8b53e826b3.tar.bz2 |
Merge #1166
1166: Support inference of generic parameters on paths behind reference's r=philberty a=philberty
We used a hack in the parser to turn simple cases such as &Foo(..) into:
BorrowExpr
CallExpr(
IdentifierExpr + <Argument-expressions>))
The IdentifierExpr here is parsed as a PathExpression but to simplify
things at the time it seemed logic to see these as identifier expressions
but this is actually a Path and we need to be careful about generic
arguments here. Identifiers are simply identifiers and must not be changed
or coherence of inference variables will become a jumble of inference
variables trying to infer one another inside purely generic code.
This patch leaves the PathInExpressions as Path's instead of trying to be
clever and turn them into identifiers.
Fixes #1165
Co-authored-by: Philip Herron <philip.herron@embecosm.com>
Diffstat (limited to 'gcc/rust/backend/rust-compile-resolve-path.cc')
0 files changed, 0 insertions, 0 deletions