Re: [cfe-users] uniquely identifying names

2016-08-31 Thread folkert via cfe-users
Oh right, indeed. Parser error (my brain) on my side: I looked for "fully q...". Mea culpa. On Tue, Aug 30, 2016 at 08:52:25PM +0200, Lucas Soltic wrote: > I don't know which API you're using, but > clang::NamedDecl::getQualifiedNameAsString seems to do what you want. > > > Le 30 août 2016 à 17:

Re: [cfe-users] uniquely identifying names

2016-08-30 Thread Lucas Soltic via cfe-users
I don't know which API you're using, but clang::NamedDecl::getQualifiedNameAsString seems to do what you want. > Le 30 août 2016 à 17:40, David Blaikie via cfe-users > a écrit : > > Do you want to identify the same entity across a valid program's various > source files? Across changes to that

Re: [cfe-users] uniquely identifying names

2016-08-30 Thread David Blaikie via cfe-users
Do you want to identify the same entity across a valid program's various source files? Across changes to that program? (what changes?) If you want to do the former, then producing the mangled name of the entity is probably what you want. (some part of the ABI code in Clang could give you that, I w

Re: [cfe-users] uniquely identifying names

2016-08-30 Thread folkert via cfe-users
Maybe I could expand a name into its full name and use that. e.g.: namespace bla { class myclass { void mymethod() { } } } then the full name of mymethod would be bla::myclass::mymethod would be unique enough to me (including filename). Can I somehow get this out of it? On Fri, Aug 26, 2016 at 0

Re: [cfe-users] uniquely identifying names

2016-08-26 Thread Anna Zaks via cfe-users
> On Aug 26, 2016, at 8:33 AM, David Blaikie via cfe-users > wrote: > > There's no structural identity of code in Clang that I know of - I know > someone's building a tool for doing structural similarity for things like > plagiarism detection (I think there are some patches on the clang maili

Re: [cfe-users] uniquely identifying names

2016-08-26 Thread David Blaikie via cfe-users
There's no structural identity of code in Clang that I know of - I know someone's building a tool for doing structural similarity for things like plagiarism detection (I think there are some patches on the clang mailing list). But if you only need identity within a single process, the pointer valu