* Querying Complete Scoped Identifier Name at Point
@ 2010-02-03 16:30 Nordlöw
2010-02-03 17:06 ` Drew Adams
0 siblings, 1 reply; 2+ messages in thread
From: Nordlöw @ 2010-02-03 16:30 UTC (permalink / raw)
To: help-gnu-emacs
Has anybody written any extension of symbol-at-point that also
includes in context, which for example in C++ means to prefix it with
its namespace if given.
For example standing somewhere at "vector" in the expression
"std::vector" should return "std::vector" instead of "vector".
This is of course trivial to write. I just wondered if anybody has
written a multi-language interface for this?
Any suggestions on what to call such a function? My suggestion is
scoped-identifier-at-point()
Maybe we should include it thingatpt+.el, Drew?
Thanks in advance,
Nordlöw
^ permalink raw reply [flat|nested] 2+ messages in thread
* RE: Querying Complete Scoped Identifier Name at Point
2010-02-03 16:30 Querying Complete Scoped Identifier Name at Point Nordlöw
@ 2010-02-03 17:06 ` Drew Adams
0 siblings, 0 replies; 2+ messages in thread
From: Drew Adams @ 2010-02-03 17:06 UTC (permalink / raw)
To: 'Nordlöw', help-gnu-emacs
> Has anybody written any extension of symbol-at-point that also
> includes in context, which for example in C++ means to prefix it with
> its namespace if given.
>
> For example standing somewhere at "vector" in the expression
> "std::vector" should return "std::vector" instead of "vector".
>
> This is of course trivial to write. I just wondered if anybody has
> written a multi-language interface for this?
>
> Any suggestions on what to call such a function? My suggestion is
> scoped-identifier-at-point()
>
> Maybe we should include it thingatpt+.el, Drew?
I'm no expert on this, but I would think that `:' should simply be declared a
symbol constituent for the language in question, if the fully qualified symbol
name includes the `std::'. Dunno.
If not, that might still be the way to go, but locally only, i.e. for the
purposes of grabbing the symbol.
The functions in `thingatpt+.el' let you specify a syntax-table arg, so you
might be able to get what you want by passing a syntax-table arg that recognizes
`:' as a symbol constituent.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-02-03 17:06 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-03 16:30 Querying Complete Scoped Identifier Name at Point Nordlöw
2010-02-03 17:06 ` Drew Adams
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.