vexyl / MCHawk

A Minecraft classic server
MIT License
8 stars 4 forks source link

Smart pointers and const correctness #41

Open vexyl opened 6 years ago

vexyl commented 6 years ago

Refactor code to use smart pointers and to be const-correct. I've already ran into a lot of issues using raw pointers. Const-correct code is less error prone and looks cleaner.

GiantCrocodile commented 6 years ago

What was your issue with raw pointers? I agree that we should have const everywhere where it fits. For example every getter and functions which just print stuff to console or file should be obviously const.