본문 바로가기

C++20/4th Emperor4

[C++20 - 4th Emperor] Chapter 04. Coroutine GitHub : https://github.com/developeSHG/CPP20-4th_Emperor/commit/19ff2673e96a446bee711c99873b180d69b52391 Coroutine · developeSHG/CPP20-4th_Emperor@19ff267 developeSHG committed Jul 26, 2023 github.com Module 기능과 함께 가장 중요한 기능인 Coroutine // 유니티 = 코루틴 // - C#에서 있는 코루틴 문법을 유니티에서 적극적으로 채용해서 제공 어떤 함수를 호출할 때, 함수를 어디까지 진행했는지 저장하고, 일시정지했다가 다시 이어서 호출할 수 있는 기능 간단히 말해서 내가 원할 때, 핸들을 이용해 코드를 다시 재게하거나 제거해버리는 .. 2023. 7. 25.
[C++20 - 4th Emperor] Chapter 03. Range GitHub : https://github.com/developeSHG/CPP20-4th_Emperor/commit/f7e318d8e7ff816fc029ec7544e8191798030035 Range · developeSHG/CPP20-4th_Emperor@f7e318d developeSHG committed Jul 25, 2023 github.com C# LINQ 문법이랑 비슷하다. #include using namespace std; #include #include #include #include #include // Range #include // 오늘의 주제 : Range template requires std::ranges::view // concept 문법 class ContainerView .. 2023. 7. 25.
[C++20 - 4th Emperor] Chapter 02. Module GitHub : https://github.com/developeSHG/CPP20-4th_Emperor/commit/7845069f15683d59fe2db806c997dfd7743fe475 Module · developeSHG/CPP20-4th_Emperor@7845069 developeSHG committed Jul 25, 2023 github.com C++20에 들어간 모든 기능을 통틀어서, 가장 중요하다 생각. C++20은 다른 언어들에 비해서 속도가 빠른 것이 장점 중 하나. 반면, 큰 단점은 문법이 복잡한편이다. 빌드 속도도 오래걸리는 편이다. 실행속도는 빠르다고 했지만, 실행하려면 우선 빌드가 통과해야 되고, 결과물을 추출한 다음 실행하게 되는데 그렇다면, 빌드 속도가 느려진다고 하면 큰 문제.. 2023. 7. 25.
[C++20 - 4th Emperor] Chapter 01. Concept GitHub : https://github.com/developeSHG/CPP20-4th_Emperor/commit/978ee4946379c5c446ef2d1fb9e7f8354ec1e671 Concept · developeSHG/CPP20-4th_Emperor@978ee49 developeSHG committed Jul 24, 2023 github.com // static void TestObject(T obj) where T : GameObject C#에는 제네릭 문법(C++의 템플릿과 유사)을 통해 타입을 동적으로 생성하면서 where를 통해 타입에 대해 부가적인 조건을 걸어 (어떤 클래스에 파생된다든지) 원하는 타입을 생성할 수 있었다. using System; namespace CSharp { c.. 2023. 7. 24.