Błąd kompilatora C3842Compiler Error C3842
"Function": kwalifikatory "const" i "volatile" dla funkcji składowych WinRT lub typów zarządzanych nie są obsługiwane'function': 'const' and 'volatile' qualifiers on member functions of WinRT or managed types are not supported
funkcje const i volatile nie są obsługiwane w funkcjach składowych typu środowisko wykonawcze systemu Windows lub Managed.const and volatile are not supported on member functions of Windows Runtime or managed types.
Poniższy przykład generuje C3842:The following sample generates C3842:
// C3842a.cpp
// compile with: /clr /c
public ref struct A {
void f() const {} // C3842
void f() volatile {} // C3842
void f() {}
};