Skip to content
Unverified Commit 43d2ef28 authored by jeanPerier's avatar jeanPerier Committed by GitHub
Browse files

[flang][lowering] propagate location info of macro expansions (#67446)

Currently flang-new -g is failing when compiling code containing a call
in a macro to a function defined in the same file.

The verification added in https://reviews.llvm.org/D157447 is valid,
flang lowering was failing to propagate location information in code
from macro expansion because GetSourcePositionRange does not work with
them (it fails to come with an end location), but we do not need a range
for the MLIR location, only the start.

Use GetSourcePosition instead that works with code from macro expansion.

Note that the source location is the one of the statement where the
macro appeared, if needed some FusedLocation could be later built to
keep a link to the macro location in the debug info.
parent ebfea261
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment