Bug 15821 - [3.4 Regression] Duplicate namespace alias within namespace rejected
Summary: [3.4 Regression] Duplicate namespace alias within namespace rejected
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 3.4.0
: P2 critical
Target Milestone: 3.4.1
Assignee: Not yet assigned to anyone
URL:
Keywords: rejects-valid
Depends on:
Blocks:
 
Reported: 2004-06-04 15:00 UTC by Stephan Bergmann
Modified: 2004-09-09 23:40 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work: 4.0 3.3.3
Known to fail: 3.4.0
Last reconfirmed: 2004-06-04 15:09:13


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stephan Bergmann 2004-06-04 15:00:43 UTC
The code

  namespace a {}
  namespace b {
    namespace c = a;
    namespace c = a;
  }

fails for 3.4.0 ("declaration of 'namespace c = a;' conflicts with previous
declaration 'namespace c = a;'"), but works for 3.3.3.  The simpler code

  namespace a {}
  namespace c = a;
  namespace c = a;

works for both 3.4.0 and 3.3.3.
Comment 1 Andrew Pinski 2004-06-04 15:09:12 UTC
Confirmed, this is a regression, I do not know if this works in 3.4.1 but it does work in 3.5.0.
Comment 2 Wolfgang Bangerth 2004-06-04 15:44:02 UTC
Mark fixed this for 3.4.1 and mainline a few days ago. 
W.