Bonjour a tous.
Avec la d�pr�ciation des sp�cifications d'exception en C++11, je cherche un moyen de generer un warning dans un cas similaire a ce qui suit :
Avec une bidouille de macro, on peut
Code : S�lectionner tout - Visualiser dans une fen�tre � part
1
2
3
4
5 struct F{ void foo() throw (int){} }; int main() {}
Mais ca n'enchante pas vraiment de red�finir throw comme ca...
Code : S�lectionner tout - Visualiser dans une fen�tre � part
1
2
3
4 class __attribute__((deprecated)) old_style_throw_specification; class old_style_throw_specification {}; #define throw(...) throw(old_style_throw_specification, __VA_ARGS__)
Si quelqu'un a une autre solution, je suis preneur !
Partager