bates64 / papermario-dx

Base for Paper Mario romhacks
82 stars 26 forks source link

Use `#pragma once` as include guard #54

Open bates64 opened 7 months ago

bates64 commented 7 months ago

In many header files (*.h), we do something like

#ifndef NAME_OF_HEADER_H
#define NAME_OF_HEADER_H

// code here...

#endif

We're using a modern compiler now, so these could just be replaced by:

#pragma once

// rest of code here...

This applies to any and all header files, except for those where the macro that is defined is used elsewhere (e.g. #if DX pops up in places).