Skip to content

Commit f1f9f54

Browse files
committed
Merge pull request #111244 from Ivorforce/dont-include-array
Remove `Array` include from `dictionary.h` and `ustring.h`.
2 parents e437cfa + dc5e615 commit f1f9f54

File tree

7 files changed

+10
-4
lines changed

7 files changed

+10
-4
lines changed

core/extension/gdextension_special_compat_hashes.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@
3636
#include "core/templates/hash_map.h"
3737
#include "core/templates/local_vector.h"
3838

39+
class Array;
40+
3941
// Note: In most situations, compatibility methods should be registered via ClassDB::bind_compatibility_method().
4042
// This class is only meant to be used in exceptional circumstances, for example, when Godot's hashing
4143
// algorithm changes and registering compatibility methods for all affect methods would be onerous.

core/string/node_path.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@
3333
#include "core/string/string_name.h"
3434
#include "core/string/ustring.h"
3535

36+
#include <climits>
37+
3638
class [[nodiscard]] NodePath {
3739
struct Data {
3840
SafeRefCount refcount;

core/string/ustring.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
#include "ustring.h"
3232

3333
STATIC_ASSERT_INCOMPLETE_TYPE(class, Dictionary);
34+
STATIC_ASSERT_INCOMPLETE_TYPE(class, Array);
3435

3536
#include "core/crypto/crypto_core.h"
3637
#include "core/math/color.h"

core/string/ustring.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@
3737
#include "core/templates/hashfuncs.h"
3838
#include "core/templates/vector.h"
3939
#include "core/typedefs.h"
40-
#include "core/variant/array.h"
4140

4241
class String;
4342
template <typename T>

core/variant/callable.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#include "core/object/object_id.h"
3434
#include "core/string/string_name.h"
3535

36+
class Array;
3637
class Object;
3738
class Variant;
3839
class CallableCustom;

core/variant/dictionary.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@
3030

3131
#include "dictionary.h"
3232

33+
STATIC_ASSERT_INCOMPLETE_TYPE(class, Array);
34+
3335
#include "core/templates/hash_map.h"
3436
#include "core/templates/safe_refcount.h"
3537
#include "core/variant/container_type_validate.h"

core/variant/dictionary.h

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,14 @@
3030

3131
#pragma once
3232

33-
#include "core/string/ustring.h"
3433
#include "core/templates/hash_map.h"
3534
#include "core/templates/local_vector.h"
3635
#include "core/templates/pair.h"
37-
#include "core/variant/array.h"
3836
#include "core/variant/variant_deep_duplicate.h"
3937

38+
class Array;
39+
class StringName;
4040
class Variant;
41-
4241
struct ContainerType;
4342
struct ContainerTypeValidate;
4443
struct DictionaryPrivate;

0 commit comments

Comments
 (0)