[cfe-dev] Suggestion for C++ migration tool: tr1 removal
Vane, Edwin
edwin.vane at intel.com
Thu Feb 28 16:11:57 PST 2013
Would you log an enhancement in bugzilla too?
-----Original Message-----
From: Marshall Clow [mailto:mclow.lists at gmail.com]
Sent: Thursday, February 28, 2013 5:07 PM
To: cfe-dev at cs.uiuc.edu Developers
Cc: Vane, Edwin; klimek at google.com
Subject: Suggestion for C++ migration tool: tr1 removal
TR1 was a very successful add-on to C++03.
However, most (if not all) of the bits of TR1 are now part of the C++11 standard.
Some c++11 standard library implementations include the TR1 features (libstdc++, Dinkumware), while others (libc++) do not.
I think it would be great if the c++11 migration tool "migrated" away from using tr1 features in favor of using the ones in std.
For example:
#include <tr1/unordered_map>
int main()
{
std::tr1::unordered_map <int, int> ma;
std::cout << ma.size () << std::endl;
return 0;
}
should be rewritten to:
#include <unordered_map>
int main()
{
std::unordered_map <int, int> ma;
std::cout << ma.size () << std::endl;
return 0;
}
and so on.
Comments?
-- Marshall
More information about the cfe-dev
mailing list