Remove using namespace from Library
This commit is contained in:
@@ -2,22 +2,20 @@
|
||||
#define LOCALE_H
|
||||
#include <locale>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
using namespace std;
|
||||
namespace platform {
|
||||
struct separation : numpunct<char> {
|
||||
struct separation : std::numpunct<char> {
|
||||
char do_decimal_point() const { return ','; }
|
||||
char do_thousands_sep() const { return '.'; }
|
||||
string do_grouping() const { return "\03"; }
|
||||
std::string do_grouping() const { return "\03"; }
|
||||
};
|
||||
class ConfigLocale {
|
||||
public:
|
||||
explicit ConfigLocale()
|
||||
{
|
||||
locale mylocale(cout.getloc(), new separation);
|
||||
locale::global(mylocale);
|
||||
cout.imbue(mylocale);
|
||||
std::locale mylocale(std::cout.getloc(), new separation);
|
||||
std::locale::global(mylocale);
|
||||
std::cout.imbue(mylocale);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
Reference in New Issue
Block a user