This documentation is archived and is not being maintained.

ATL Provider Error ATL2057

Visual Studio 2008
Derive from either class or template<class>, not both.

The class is derived from a class and a template that are incompatible. To resolve, remove the derivation from either the class or the template.

The following sample generates ATL2057.

// ATL2057.cpp
// compile with: /c
// ATL2057 expected
#include <atlbase.h>
#include <atlcom.h>

[ dual ]
__interface IATL2057 : IDispatch
   HRESULT Method1();

[ coclass ]
class CATL2057 : public IDispatchImpl<IATL2057>
   public IATL2057 // to resolve, comment this line out

   public :
   HRESULT Method1()
      return S_OK;