mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-26 21:12:07 +00:00
Remove commented-out C-only macro features
This commit is contained in:
@@ -11,9 +11,7 @@
|
||||
|
||||
#include "asm/section.hpp"
|
||||
|
||||
#include "platform.hpp" // MIN_NB_ELMS
|
||||
|
||||
#define MAXSYMLEN 255
|
||||
#define MAXSYMLEN 255
|
||||
|
||||
enum SymbolType {
|
||||
SYM_LABEL,
|
||||
@@ -72,7 +70,7 @@ void sym_SetExportAll(bool set);
|
||||
Symbol *sym_AddLocalLabel(char const *symName);
|
||||
Symbol *sym_AddLabel(char const *symName);
|
||||
Symbol *sym_AddAnonLabel();
|
||||
void sym_WriteAnonLabelName(char buf[MIN_NB_ELMS(MAXSYMLEN + 1)], uint32_t ofs, bool neg);
|
||||
void sym_WriteAnonLabelName(char buf[/* MAXSYMLEN + 1 */], uint32_t ofs, bool neg);
|
||||
void sym_Export(char const *symName);
|
||||
Symbol *sym_AddEqu(char const *symName, int32_t value);
|
||||
Symbol *sym_RedefEqu(char const *symName, int32_t value);
|
||||
|
||||
@@ -8,11 +8,11 @@
|
||||
|
||||
extern "C" {
|
||||
|
||||
void warn(char const NONNULL(fmt), ...) format_(printf, 1, 2);
|
||||
void warnx(char const NONNULL(fmt), ...) format_(printf, 1, 2);
|
||||
void warn(char const *fmt ...) format_(printf, 1, 2);
|
||||
void warnx(char const *fmt, ...) format_(printf, 1, 2);
|
||||
|
||||
[[noreturn]] void err(char const NONNULL(fmt), ...) format_(printf, 1, 2);
|
||||
[[noreturn]] void errx(char const NONNULL(fmt), ...) format_(printf, 1, 2);
|
||||
[[noreturn]] void err(char const *fmt, ...) format_(printf, 1, 2);
|
||||
[[noreturn]] void errx(char const *fmt, ...) format_(printf, 1, 2);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -45,12 +45,6 @@
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
|
||||
// C++ doesn't support `[static N]` for array arguments from C99 or C11
|
||||
#define MIN_NB_ELMS(N) // static (N)
|
||||
#define ARR_QUALS(...) // __VA_ARGS__
|
||||
#define NONNULL(ptr) *ptr // ptr[static 1]
|
||||
#define restrict
|
||||
|
||||
// MSVC uses a different name for O_RDWR, and needs an additional _O_BINARY flag
|
||||
#ifdef _MSC_VER
|
||||
# include <fcntl.h>
|
||||
|
||||
Reference in New Issue
Block a user