C++ - 2019

class VoxelGrid : public Serializable { public: virtual void serialize(Archive& ar) override; }; Everything looked perfect. No typos. No missing includes. The virtual keyword matched. The override was correct.

There it was, in VoxelGrid.cpp :

Leo laughed. It was a hollow, sleep-deprived laugh that turned into a cough. He added the const , rebuilt, and the linker error vanished. The executable spun to life. c++ 2019

They looked identical. Wait. He squinted.

In the .cpp file, he had written: void VoxelGrid::serialize(Archive& ar) { class VoxelGrid : public Serializable { public: virtual

He closed Visual Studio, which took an unusually long time to shut down, as if it was reluctant to let him go. He leaned back, looked at the rain, and thought: I could have written this in Rust. But then who would keep the ghosts of C++ alive?

Tomorrow, he would refactor it to C++20. He heard std::span was finally stable. But tonight, he had earned his sleep. The virtual keyword matched

He clicked .

c++ 2019
Закрыть
Перейти