locale_classes.h error?

Ok so I was here minding my own business making a new class, and I go to build and I get an error in locale_classes.h. I've never seen anything like this, and not sure what it's problem is.

The message I'm getting is:
expected unqualified-id before 'namespace'
closed account (o3hC5Di1)
Hi there,

Could you please post a part of the code, at least where you're using or declaring namespaces?

All the best,
NwN
I personally am not declaring any namespaces of my own. Here is the section of the header I get brought to:

1
2
3
4
5
6
7
8
9
10
#ifndef _LOCALE_CLASSES_H
#define _LOCALE_CLASSES_H 1

#pragma GCC system_header

#include <bits/localefwd.h>
#include <string>
#include <ext/atomicity.h>

_GLIBCXX_BEGIN_NAMESPACE(std)


It goes on to define the locale class below this. The debugger brings me to that last line there
closed account (o3hC5Di1)
Hi,

Strange!
I found a few bits on google on this, but no real solutions.
One thing that worked for smeone was to put a semicolon after the closing brace of the class }; - worth checking out, otherwise one of the many experts on here will need to help you out.

Sorry I can't be of more help.

All the best,
NwN
Wow that worked. It's always the semicolon that kills me. Leads to the strangest errors.
closed account (o3hC5Di1)
Haha, great!

You're right - semicolon hunting can be arduous.

-N
Topic archived. No new replies allowed.