Skip to content
Snippets Groups Projects
Commit ac957a62 authored by Piotr Trojanek's avatar Piotr Trojanek Committed by Marc Poulhiès
Browse files

ada: Evaluate calls to GNAT.Source_Info routines in semantic checking

When semantic checking mode is active, i.e. when switch -gnatc is
present or when the frontend is operating in the GNATprove mode,
we now rewrite calls to GNAT.Source_Info routines in evaluation
and not expansion (which is disabled in these modes).

This is needed to recognize constants initialized with calls to
GNAT.Source_Info as static constants, regardless of expansion being
enabled.

gcc/ada/

	* exp_intr.ads, exp_intr.adb (Expand_Source_Info): Move
	declaration to package spec.
	* sem_eval.adb (Eval_Intrinsic_Call): Evaluate calls to
	GNAT.Source_Info where possible.
parent 7b77938c
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment