21
21
22
22
// NOTE: the methods are generally implemented on Godot types (e.g. AABB, not Aabb)
23
23
24
+ // This file is deliberately private -- all checks must go through `special_cases`.
25
+
24
26
#![ allow( clippy:: match_like_matches_macro) ] // if there is only one rule
25
27
26
28
use crate :: conv:: to_enum_type_uncached;
@@ -29,7 +31,6 @@ use crate::models::json::{JsonBuiltinMethod, JsonClassMethod, JsonUtilityFunctio
29
31
use crate :: special_cases:: codegen_special_cases;
30
32
use crate :: Context ;
31
33
use proc_macro2:: Ident ;
32
- // Deliberately private -- all checks must go through `special_cases`.
33
34
34
35
#[ rustfmt:: skip]
35
36
pub fn is_class_method_deleted ( class_name : & TyName , method : & JsonClassMethod , ctx : & mut Context ) -> bool {
@@ -62,7 +63,7 @@ pub fn is_class_method_deleted(class_name: &TyName, method: &JsonClassMethod, ct
62
63
| ( "VisualShaderNodeComment" , "set_description" )
63
64
| ( "VisualShaderNodeComment" , "get_description" )
64
65
=> true ,
65
-
66
+
66
67
// Workaround for methods unexposed in Release mode, see https://github.com/godotengine/godot/pull/100317
67
68
// and https://github.com/godotengine/godot/pull/100328.
68
69
#[ cfg( not( debug_assertions) ) ]
@@ -840,9 +841,9 @@ pub fn is_enum_private(class_name: Option<&TyName>, enum_name: &str) -> bool {
840
841
}
841
842
842
843
/// Certain enums that are extremely unlikely to get new identifiers in the future.
843
- ///
844
+ ///
844
845
/// `class_name` = None for global enums.
845
- ///
846
+ ///
846
847
/// Very conservative, only includes a few enums. Even `VariantType` was extended over time.
847
848
/// Also does not work for any enums containing duplicate ordinals.
848
849
#[ rustfmt:: skip]
@@ -873,7 +874,7 @@ pub fn is_enum_bitfield(class_name: Option<&TyName>, enum_name: &str) -> Option<
873
874
match ( class_name, enum_name) {
874
875
| ( Some ( "Object" ) , "ConnectFlags" )
875
876
876
- => Some ( true ) ,
877
+ => Some ( true ) ,
877
878
_ => None
878
879
}
879
880
}
0 commit comments