Bug 12284 - IWBN to not have to quote anonymous namespaces
Summary: IWBN to not have to quote anonymous namespaces
Status: NEW
Alias: None
Product: gdb
Classification: Unclassified
Component: c++ (show other bugs)
Version: HEAD
: P2 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-02 17:39 UTC by dje
Modified: 2014-07-29 21:02 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:
Project(s) to access:
ssh public key:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description dje 2010-12-02 17:39:41 UTC
This works:

(gdb) p 'foo::(anonymous namespace)::bar'

This doesn't, but IWBN if it did:

(gdb) p foo::(anonymous namespace)::bar

Testcase:

namespace foo
{
  namespace
  {
    int bar;
  }
}

int
main ()
{
  return 0;
}
Comment 1 Tom Tromey 2013-03-06 19:39:17 UTC
It seems to me that having to enter "(anonymous namespace)"
at all is a bug.  At least as far as expression parsing goes --
I'm less sure about linespecs.
Comment 2 Tom Tromey 2013-07-14 18:26:35 UTC
(In reply to Tom Tromey from comment #1)
> It seems to me that having to enter "(anonymous namespace)"
> at all is a bug.  At least as far as expression parsing goes --
> I'm less sure about linespecs.

It seems to me now that this should also be droppable for
linespecs.