mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 18:22:07 +00:00
Consistently format type qualifiers like const on the right (#1347)
This commit is contained in:
@@ -40,7 +40,7 @@ struct FileStackNode {
|
||||
std::string const &name() const;
|
||||
|
||||
FileStackNode(FileStackNodeType type_, std::variant<std::vector<uint32_t>, std::string> data_)
|
||||
: type(type_), data(data_) {};
|
||||
: type(type_), data(data_){};
|
||||
|
||||
void dump(uint32_t curLineNo) const;
|
||||
};
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
struct Expression;
|
||||
struct FileStackNode;
|
||||
|
||||
extern const char *objectName;
|
||||
extern char const *objectName;
|
||||
|
||||
void out_RegisterNode(FileStackNode *node);
|
||||
void out_ReplaceNode(FileStackNode *node);
|
||||
|
||||
@@ -27,7 +27,7 @@ struct Expression {
|
||||
Expression(Expression &&) = default;
|
||||
#ifdef _MSC_VER
|
||||
// MSVC and WinFlexBison won't build without this...
|
||||
Expression(const Expression &) = default;
|
||||
Expression(Expression const &) = default;
|
||||
#endif
|
||||
|
||||
Expression &operator=(Expression &&) = default;
|
||||
@@ -36,10 +36,10 @@ struct Expression {
|
||||
void rpn_Number(Expression &expr, uint32_t val);
|
||||
void rpn_Symbol(Expression &expr, char const *symName);
|
||||
void rpn_LOGNOT(Expression &expr, Expression &&src);
|
||||
void rpn_BinaryOp(RPNCommand op, Expression &expr, Expression &&src1, const Expression &src2);
|
||||
void rpn_BinaryOp(RPNCommand op, Expression &expr, Expression &&src1, Expression const &src2);
|
||||
void rpn_HIGH(Expression &expr, Expression &&src);
|
||||
void rpn_LOW(Expression &expr, Expression &&src);
|
||||
void rpn_ISCONST(Expression &expr, const Expression &src);
|
||||
void rpn_ISCONST(Expression &expr, Expression const &src);
|
||||
void rpn_NEG(Expression &expr, Expression &&src);
|
||||
void rpn_NOT(Expression &expr, Expression &&src);
|
||||
void rpn_BankSymbol(Expression &expr, char const *symName);
|
||||
@@ -52,6 +52,6 @@ void rpn_StartOfSectionType(Expression &expr, SectionType type);
|
||||
|
||||
void rpn_CheckHRAM(Expression &expr);
|
||||
void rpn_CheckRST(Expression &expr);
|
||||
void rpn_CheckNBit(const Expression &expr, uint8_t n);
|
||||
void rpn_CheckNBit(Expression const &expr, uint8_t n);
|
||||
|
||||
#endif // RGBDS_ASM_RPN_H
|
||||
|
||||
2
include/extern/getopt.hpp
vendored
2
include/extern/getopt.hpp
vendored
@@ -18,7 +18,7 @@ struct option {
|
||||
};
|
||||
|
||||
int musl_getopt_long_only(
|
||||
int argc, char **argv, char const *optstring, const option *longopts, int *idx
|
||||
int argc, char **argv, char const *optstring, option const *longopts, int *idx
|
||||
);
|
||||
|
||||
#define no_argument 0
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
#ifdef _MSC_VER
|
||||
#define S_IFMT _S_IFMT
|
||||
#define S_IFDIR _S_IFDIR
|
||||
#define S_ISDIR(mode) (((mode) & S_IFMT) == S_IFDIR)
|
||||
#define S_ISDIR(mode) (((mode)&S_IFMT) == S_IFDIR)
|
||||
#endif
|
||||
|
||||
// MSVC doesn't use POSIX types or defines for `read`
|
||||
@@ -40,7 +40,7 @@
|
||||
#ifdef _MSC_VER
|
||||
#include <fcntl.h>
|
||||
#define O_RDWR _O_RDWR
|
||||
#define S_ISREG(field) ((field) & _S_IFREG)
|
||||
#define S_ISREG(field) ((field)&_S_IFREG)
|
||||
#define O_BINARY _O_BINARY
|
||||
#define O_TEXT _O_TEXT
|
||||
#elif !defined(O_BINARY) // Cross-compilers define O_BINARY
|
||||
|
||||
Reference in New Issue
Block a user