diff options
author | Javier Miranda <miranda@adacore.com> | 2016-07-06 13:45:55 +0000 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2016-07-06 15:45:55 +0200 |
commit | a5fa15228d5eecb6db3029c44a6a24ded6f68818 (patch) | |
tree | 62e379af78ddd2fd2ad9bef42dfd549fc77b4511 /gcc | |
parent | 6dfc5e671f592499d162ccf2cadd17b9de9d090c (diff) | |
download | gcc-a5fa15228d5eecb6db3029c44a6a24ded6f68818.zip gcc-a5fa15228d5eecb6db3029c44a6a24ded6f68818.tar.gz gcc-a5fa15228d5eecb6db3029c44a6a24ded6f68818.tar.bz2 |
sem_ch6.adb (Check_Inline_Pragma): if the subprogram has no spec then move its aspects to the internally built...
2016-07-06 Javier Miranda <miranda@adacore.com>
* sem_ch6.adb (Check_Inline_Pragma): if the subprogram has no spec
then move its aspects to the internally built subprogram spec.
From-SVN: r238052
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/ada/sem_ch6.adb | 6 |
2 files changed, 11 insertions, 0 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 98e47fb..8954f8b 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2016-07-06 Javier Miranda <miranda@adacore.com> + + * sem_ch6.adb (Check_Inline_Pragma): if the subprogram has no spec + then move its aspects to the internally built subprogram spec. + 2016-07-06 Yannick Moy <moy@adacore.com> * sem_ch6.adb (Analyze_Expression_Function): Mark body of diff --git a/gcc/ada/sem_ch6.adb b/gcc/ada/sem_ch6.adb index a47ebda..c9c0f7f 100644 --- a/gcc/ada/sem_ch6.adb +++ b/gcc/ada/sem_ch6.adb @@ -2665,6 +2665,12 @@ package body Sem_Ch6 is (Specification (Decl), Plist); end if; + -- Move aspects to the new spec + + if Has_Aspects (N) then + Move_Aspects (N, To => Decl); + end if; + Insert_Before (N, Decl); Analyze (Decl); Analyze (Prag); |