Skip to content

EliseBriers/spaceship-operator-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The spaceship operator (<=>)

Git repo for the video Reduce Boilerplate Code With The C++ Spaceship Operator (<=>).
By Elise++


Introduction

This repo contains all the code files shown in the video Reduce Boilerplate Code With The C++ Spaceship Operator (<=>). It shows an example of how this new operator can reduce boilerplate code by auto generating most of the other operators.

Building and testing

Manually

Build the project using cmake and a compiler with C++ 20 abilities. Most modern compilers should work. Making the file will result in the unit tests getting executed automatically.

git clone https://github.com/EliseBriers/spaceship-operator-examples
cd spaceship-operator-examples
mkdir build
cd build
cmake ..
cmake --build .

Visual Studio (Windows)

The easiest way to build and run the project on windows is opening it in a recent version of Vidual Studio. This project has been tested using Visual Studio 2022.

About

Examples for the C++ 20 spaceship (<=>) operator.

Resources

License

Stars

Watchers

Forks