aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-ifcombine.c
diff options
context:
space:
mode:
authorPhilip Herron <philip.herron@embecosm.com>2021-11-23 17:09:52 +0000
committerPhilip Herron <philip.herron@embecosm.com>2021-11-23 23:01:04 +0000
commit8b36f2b80ebd0e0304b6df4020b5992640662667 (patch)
treefad38abf4fc4875a2d3c72336a154d3892a7f1a6 /gcc/tree-ssa-ifcombine.c
parenta41851dfb5bec6f40fd89db01ae75fee557306ee (diff)
downloadgcc-8b36f2b80ebd0e0304b6df4020b5992640662667.zip
gcc-8b36f2b80ebd0e0304b6df4020b5992640662667.tar.gz
gcc-8b36f2b80ebd0e0304b6df4020b5992640662667.tar.bz2
Set TREE_ADDRESSABLE when we need to borrow any expression
GCC requires VAR_DECL's and PARAM_DECL's to be marked with TREE_ADDRESSABLE when the declaration will be used in borrow's ('&' getting the address). This takes into account the implicit addresses when we do autoderef in method resolution/operator-overloading. This patch keeps a seperate side table for the VAR_DECL/PARAM_DECL hir-id's for lookup. The typechecker marks these id's using AddressTakenResolver::SetAddressTaken (HIR::Expr&); Its quite simple as it only cares about paths such as: - PathInExpression - QualifiedPathInExpression - IdentifierExpression The rest of the expression types will be folded into temporary values anyway so they don't need to be marked as needs_address. Fixes #804
Diffstat (limited to 'gcc/tree-ssa-ifcombine.c')
0 files changed, 0 insertions, 0 deletions