projects
/
gcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b03a25f
)
[Ada] Inlining nonstatic calls to static expression functions
author
Gary Dismukes
<dismukes@adacore.com>
Fri, 17 Jul 2020 22:28:52 +0000
(18:28 -0400)
committer
Pierre-Marie de Rodat
<derodat@adacore.com>
Tue, 20 Oct 2020 07:21:40 +0000
(
03:21
-0400)
gcc/ada/
* sem_ch6.adb (Analyze_Expression_Function): Mark static
expression functions as inlined.
gcc/ada/sem_ch6.adb
patch
|
blob
|
history
diff --git
a/gcc/ada/sem_ch6.adb
b/gcc/ada/sem_ch6.adb
index f314f1bde3fc982ec6202827b0fec0128654b284..215c4ada782f067552c686f62998fd6256070f55 100644
(file)
--- a/
gcc/ada/sem_ch6.adb
+++ b/
gcc/ada/sem_ch6.adb
@@
-609,6
+609,12
@@
package body Sem_Ch6 is
Set_Expression
(Original_Node (Subprogram_Spec (Def_Id)),
New_Copy_Tree (Expr));
+
+ -- Mark static expression functions as inlined, to ensure
+ -- that even calls with nonstatic actuals will be inlined.
+
+ Set_Has_Pragma_Inline (Def_Id);
+ Set_Is_Inlined (Def_Id);
end if;
end if;
end;