diff options
author | Javier Miranda <miranda@adacore.com> | 2024-07-06 19:07:16 +0000 |
---|---|---|
committer | Marc Poulhiès <dkm@gcc.gnu.org> | 2024-08-02 09:08:06 +0200 |
commit | ee7945e367c2e9a1127aac0c11c078638601258d (patch) | |
tree | 8f0e3b0f7308d1c3ee82eb7aa5bf8f70ec907baa /gcc/ada/doc/gnat_rm | |
parent | 30ba62d91ff96b0f86cc1a8544dd1ed30196ca40 (diff) | |
download | gcc-ee7945e367c2e9a1127aac0c11c078638601258d.zip gcc-ee7945e367c2e9a1127aac0c11c078638601258d.tar.gz gcc-ee7945e367c2e9a1127aac0c11c078638601258d.tar.bz2 |
ada: Reject ambiguous function calls in interpolated string expressions
This patch enhances support for this language feature by rejecting
more ambiguous function calls. In terms of name resolution, the
analysis of interpolated expressions is now treated as an expression
of any type, as required by the documentation. Additionally, support
for nested interpolated strings has been removed.
gcc/ada/
* gen_il-fields.ads (Is_Interpolated_String_Literal): New field.
* gen_il-gen-gen_nodes.adb (Is_Interpolated_String_Literal): The
new field is a flag handled by the parser (syntax flag).
* par-ch2.adb (P_Interpolated_String_Literal): Decorate the new
flag.
* sem_ch2.adb (Analyze_Interpolated_String_Literal): Improve code
detecting and reporting ambiguous function calls.
* sem_res.adb (Resolve_Interpolated_String_Literal): Restrict
resolution imposed by the context type to string literals that
have the new flag.
* sinfo.ads (Is_Interpolated_String_Literal): New field defined in
string literals. Fix documentation of the syntax rule of
interpolated string literal.
Diffstat (limited to 'gcc/ada/doc/gnat_rm')
0 files changed, 0 insertions, 0 deletions