[Ada] Spurious condition warning on type conversion in return
authorJustin Squirek <squirek@adacore.com>
Thu, 30 Apr 2020 20:04:26 +0000 (16:04 -0400)
committerPierre-Marie de Rodat <derodat@adacore.com>
Fri, 19 Jun 2020 08:17:22 +0000 (04:17 -0400)
commit650abc2c93ab2e599df3053c8556e70de003dd79
tree76d7ddf794b24fe2e9b2fad4f1cafd5f52edbc38
parenta6d7dfbbb2f1fe25e040a31f17c03d292b5b5b61
[Ada] Spurious condition warning on type conversion in return

2020-06-19  Justin Squirek  <squirek@adacore.com>

gcc/ada/

* sem_warn.adb (Warn_On_Known_Condition): Add general sanity
check that asserts the original source node being checked
contains an entity. If not, it could be the result of special
case expansion for type conversions.
gcc/ada/sem_warn.adb