aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-object-size.h
diff options
context:
space:
mode:
authorPiotr Trojanek <trojanek@adacore.com>2022-01-20 18:05:39 +0100
committerPierre-Marie de Rodat <derodat@adacore.com>2022-05-10 08:19:28 +0000
commit45c4d9193dd33013522ff7e7f8f90f77d20cb7be (patch)
tree8223f62aacf8b603688862ab8c2366dd91740f3f /gcc/tree-object-size.h
parentce63a97b518915b3b6c1221da60af719c7eccd5a (diff)
downloadgcc-45c4d9193dd33013522ff7e7f8f90f77d20cb7be.zip
gcc-45c4d9193dd33013522ff7e7f8f90f77d20cb7be.tar.gz
gcc-45c4d9193dd33013522ff7e7f8f90f77d20cb7be.tar.bz2
[Ada] Remove repeated conversions between Source_Ptr and Int
Both Source_Ptr and Int are integer types (and even happen to have equal ranges). Their values can be calculated without converting back-and-forth, e.g.: Int (Loc1) - Int (Loc2) can be written simply as: Int (Loc1 - Loc2) Code cleanup related to handling of references to unset objects. Offending occurrences found with various invocations of grep. gcc/ada/ * par-ch10.adb, scng.adb, sem_res.adb, sinfo-utils.adb, treepr.adb: Simplify calculations with Source_Ptr and Loc values.
Diffstat (limited to 'gcc/tree-object-size.h')
0 files changed, 0 insertions, 0 deletions