Compilerfehler C3842

Die Qualifizierer 'function': 'const' und 'volatile' in Memberfunktionen von WinRT oder verwalteten Typen werden nicht unterstützt.

const and volatile are not supported on member functions of Windows-Runtime or managed types.

Im folgenden Beispiel wird C3842 generiert:

// C3842a.cpp
// compile with: /clr /c
public ref struct A {
   void f() const {}   // C3842
   void f() volatile {}   // C3842

   void f() {}
};