This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Access to source code from an analyser


On Thu, Jan 19, 2012 at 12:56 PM, Alberto Lozano Alelu <alelus@gmail.com> wrote:
> Hello.
>
> I'm developing a C++ analyzer and I would like to get source text of
> file when I'm analyzing C++ code.
>
> When I'm analyzing source code I would like to get source text line
> from a location of a type. I have got type location but I don't know a
> function to get source line text from source location (file and line).
> I'm looking in <gcc_root_dir>/libcpp.
>
> Is there a function to get source text line from source location?

expand_location ()

> Thanks.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]