다음을 통해 공유


컴파일러 오류 C2776

속성당 'get' 메서드를 하나만 지정할 수 있습니다.

비고

속성get하나의 함수만 지정할 수 있습니다. 이 오류는 여러 get 함수를 지정할 때 발생합니다.

예시

다음 예제에서는 C2776을 생성합니다.

// C2776.cpp
struct A {
   __declspec(property(get=GetProp,get=GetPropToo))
   // try the following line instead
   // __declspec(property(get=GetProp))
      int prop;   // C2776
   int GetProp(void);
   int GetPropToo(void);
};