Namespace-scope using-declarations for class member types

Intel C++ Compiler for Windows previously accepted namespace-scope using-declarations referring to types that are class members. Now with 11.x release this is limited to modes with Microsoft* Visual Studio .NET 2003* only.

For example: 

// tst_namespace_scope.cpp

struct S { struct N {}; };
using S::N;  // No longer accepted when microsoft_version == 1400

int foo()
{
return 0;
}


C: >icl tst_namespace_scope.cpp
//Intel® C++ Compiler Professional for applications running on IA-32, Version 11.0
//Build 20080930 Package ID: w_cproc_p_11.0.061
//Copyright (C) 1985-2008 Intel Corporation
//All rights reserved


tst_namespace_scope.cpp
tst_namespace_scope.cpp(5): error: a class-qualified name is not allowed

using S::N;  // No longer accepted when microsoft_version == 1400


compilation aborted for tst_namespace_scope.cpp (code 2)

 

Para obter informações mais completas sobre otimizações do compilador, consulte nosso aviso de otimização.