Don't right-align escaped newlines, e.g. for #define. This has previously led to long diffs in the commit history.

This commit is contained in:
Lukas Tenbrink
2025-11-04 10:58:10 +01:00
parent f4f0679a2d
commit c5df0cb82b
144 changed files with 4519 additions and 4519 deletions

View File

@@ -703,12 +703,12 @@ void GDScriptParser::parse_program() {
current_class = head;
bool can_have_class_or_extends = true;
#define PUSH_PENDING_ANNOTATIONS_TO_HEAD \
if (!annotation_stack.is_empty()) { \
#define PUSH_PENDING_ANNOTATIONS_TO_HEAD \
if (!annotation_stack.is_empty()) { \
for (AnnotationNode *annot : annotation_stack) { \
head->annotations.push_back(annot); \
} \
annotation_stack.clear(); \
head->annotations.push_back(annot); \
} \
annotation_stack.clear(); \
}
while (!check(GDScriptTokenizer::Token::TK_EOF)) {
@@ -5104,14 +5104,14 @@ bool GDScriptParser::warning_ignore_annotation(AnnotationNode *p_annotation, Nod
int end_line = p_target->end_line;
switch (p_target->type) {
#define SIMPLE_CASE(m_type, m_class, m_property) \
case m_type: { \
#define SIMPLE_CASE(m_type, m_class, m_property) \
case m_type: { \
m_class *node = static_cast<m_class *>(p_target); \
if (node->m_property == nullptr) { \
end_line = node->start_line; \
} else { \
end_line = node->m_property->end_line; \
} \
if (node->m_property == nullptr) { \
end_line = node->start_line; \
} else { \
end_line = node->m_property->end_line; \
} \
} break;
// Can contain properties (set/get).