You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Add contains_char() for single-character 'contains' calls.
This commit is contained in:
@@ -106,11 +106,11 @@ Error RDShaderFile::parse_versions_from_text(const String &p_text, const String
|
||||
if (reading_versions) {
|
||||
String l = line.strip_edges();
|
||||
if (!l.is_empty()) {
|
||||
if (!l.contains("=")) {
|
||||
if (!l.contains_char('=')) {
|
||||
base_error = "Missing `=` in '" + l + "'. Version syntax is `version = \"<defines with C escaping>\";`.";
|
||||
break;
|
||||
}
|
||||
if (!l.contains(";")) {
|
||||
if (!l.contains_char(';')) {
|
||||
// We don't require a semicolon per se, but it's needed for clang-format to handle things properly.
|
||||
base_error = "Missing `;` in '" + l + "'. Version syntax is `version = \"<defines with C escaping>\";`.";
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user