-
카테고리
-
세부 분야
프로그래밍 언어
-
해결 여부
미해결
14분 04초
21.02.17 23:56 작성 조회수 124
0
void set(const position2D & pos_target
{
set(pos_target.m_x, pos_target.m_y); // 1
}
void set(const int & x_target, const int& y_target) //2
{
m_x = x_target;
m_y = y_target;
}
1부분에서 사용된 함수가 2부분에 바디가 있고,
2함수의 전방선언이 없는데
어떻게 컴파일러오류없이 1부분에서 2부분의 함수를 사용할 수 있는지 의문입니다
답변을 작성해보세요.
2
답변 1