강의

멘토링

커뮤니티

Inflearn Community Q&A

solarscw85's profile image
solarscw85

asked

[MMORPG Game Development with C++ and Unreal Series] Part 4: Game Server

TypeCast

struct 안에 private/public으로 나눠준 이유가 있나요?

Written on

·

266

0

안녕하세요

강의 중에

struct IndexOf<TypeList<Head,Tail...>, T>

{

private:

        enum{temp = IndexOf<TypeList<Tail...>, T>::value};

public:

      enum{value = (temp == -1) ? -1 : temp + 1};

}

위와 같은 코드가 있는데요

private/public으로 따로 나눠준 이유가 있을까요?

networkwindows-serverMMORPG

Answer 1

0

Rookiss님의 프로필 이미지
Rookiss
Instructor

public으로 해도 상관 없습니다.
거의 라이브 코딩에 가깝기 때문에 한줄 한줄에 큰 의미를 부여하실 필요 없습니다.

solarscw85's profile image
solarscw85

asked

Ask a question