Skip to content

Commit 0ee51e8

Browse files
committed
Merge branch 'master' into ported-escaping
2 parents 3220f7f + aa7107a commit 0ee51e8

File tree

2 files changed

+8
-11
lines changed

2 files changed

+8
-11
lines changed

godot-codegen/src/conv/type_conversions.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ fn to_rust_expr_inner(expr: &str, ty: &RustTy, is_inner: bool) -> TokenStream {
266266
return match ty {
267267
RustTy::BuiltinIdent(ident) if ident == "Variant" => quote! { Variant::nil() },
268268
RustTy::EngineClass { .. } => {
269-
quote! { unimplemented!("see https://github.com/godot-rust/gdext/issues/156") }
269+
quote! { ObjectArg::null() }
270270
}
271271
_ => panic!("null not representable in target type {ty:?}"),
272272
}

godot-codegen/src/special_cases/special_cases.rs

+7-10
Original file line numberDiff line numberDiff line change
@@ -100,14 +100,6 @@ pub fn is_godot_type_deleted(godot_ty: &str) -> bool {
100100
}
101101
}
102102

103-
// ThemeDB was previously loaded lazily
104-
// in 4.2 it loads at the Scene level
105-
// see: https://github.com/godotengine/godot/pull/81305
106-
#[cfg(before_api = "4.2")]
107-
if godot_ty == "ThemeDB" {
108-
return true;
109-
}
110-
111103
match godot_ty {
112104
// Hardcoded cases that are not accessible.
113105
// Only on Android.
@@ -135,9 +127,14 @@ pub fn is_godot_type_deleted(godot_ty: &str) -> bool {
135127
| "MovieWriterMJPEG"
136128
| "MovieWriterPNGWAV"
137129
| "ResourceFormatImporterSaver"
130+
=> true,
131+
// Previously loaded lazily; in 4.2 it loads at the Scene level. See: https://github.com/godotengine/godot/pull/81305
132+
| "ThemeDB"
133+
=> cfg!(before_api = "4.2"),
134+
// reintroduced in 4.3. See: https://github.com/godotengine/godot/pull/80214
138135
| "UniformSetCacheRD"
139-
140-
=> true, _ => false
136+
=> cfg!(before_api = "4.3"),
137+
_ => false
141138
}
142139
}
143140

0 commit comments

Comments
 (0)