Skip to content

Commit 90bae8b

Browse files
committed
Move UniformObjectDeref to godot::meta
1 parent 6037464 commit 90bae8b

File tree

5 files changed

+9
-8
lines changed

5 files changed

+9
-8
lines changed

godot-core/src/meta/args/as_arg.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ where
7272
/// once the reference is returned. Could use more fancy syntax like `arg_into_ref! { let path = ref; }` or `let path = arg_into_ref!(path)`,
7373
/// but still isn't obvious enough to avoid doc lookup and might give a wrong idea about the scope. So being more exotic is a feature.
7474
#[macro_export]
75+
#[doc(hidden)] // Doesn't work at re-export.
7576
macro_rules! arg_into_ref {
7677
($arg_variable:ident) => {
7778
// Non-generic version allows type inference. Only applicable for CowArg types.
@@ -88,6 +89,7 @@ macro_rules! arg_into_ref {
8889
///
8990
/// A macro for consistency with [`arg_into_ref`][crate::arg_into_ref].
9091
#[macro_export]
92+
#[doc(hidden)] // Doesn't work at re-export.
9193
macro_rules! arg_into_owned {
9294
($arg_variable:ident) => {
9395
// Non-generic version allows type inference. Only applicable for CowArg types.

godot-core/src/meta/mod.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ mod param_tuple;
5252
mod property_info;
5353
mod signature;
5454
mod traits;
55+
mod uniform_object_deref;
5556

5657
pub(crate) mod sealed;
5758

@@ -60,9 +61,9 @@ pub mod error;
6061
pub use args::*;
6162
pub use class_name::ClassName;
6263
pub use godot_convert::{FromGodot, GodotConvert, ToGodot};
63-
pub use traits::{ArrayElement, GodotType, PackedArrayElement};
64-
6564
pub use param_tuple::{InParamTuple, OutParamTuple, ParamTuple};
65+
pub use traits::{ArrayElement, GodotType, PackedArrayElement};
66+
pub use uniform_object_deref::UniformObjectDeref;
6667

6768
pub(crate) use array_type_info::ArrayTypeInfo;
6869
pub(crate) use traits::{

godot-core/src/registry/signal/uniform_object_deref.rs renamed to godot-core/src/meta/uniform_object_deref.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,9 @@ use std::ops::{Deref, DerefMut};
3232
///
3333
/// Despite being 2 different traits, a function can accept both by simply being generic over `Declarer`:
3434
/// ```no_run
35-
/// # use godot::register::UniformObjectDeref;
35+
/// use godot::meta::UniformObjectDeref;
3636
/// # use godot::prelude::*;
37+
///
3738
/// fn abstract_over_objects<Declarer, C>(obj: &Gd<C>)
3839
/// where
3940
/// C: UniformObjectDeref<Declarer>,

godot-core/src/registry/signal/mod.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,17 @@
1010
mod connect_builder;
1111
mod signal_object;
1212
mod typed_signal;
13-
mod uniform_object_deref;
1413

1514
use crate::builtin::{GString, Variant};
1615
use crate::meta;
1716
pub(crate) use connect_builder::*;
1817
pub(crate) use signal_object::*;
1918
pub(crate) use typed_signal::*;
20-
use uniform_object_deref::UniformObjectDeref;
2119

2220
// Used in `godot` crate.
2321
pub mod re_export {
2422
pub use super::connect_builder::ConnectBuilder;
2523
pub use super::typed_signal::TypedSignal;
26-
pub use super::uniform_object_deref::UniformObjectDeref;
2724
}
2825

2926
// Used in `godot::private` module.

godot-core/src/registry/signal/typed_signal.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@
55
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
66
*/
77

8-
use super::{make_callable_name, make_godot_fn, ConnectBuilder, SignalObject, UniformObjectDeref};
8+
use super::{make_callable_name, make_godot_fn, ConnectBuilder, SignalObject};
99
use crate::builtin::{Callable, Variant};
1010
use crate::classes::object::ConnectFlags;
1111
use crate::meta;
12-
use crate::meta::FromGodot;
12+
use crate::meta::{FromGodot, UniformObjectDeref};
1313
use crate::obj::{Gd, GodotClass, WithBaseField, WithSignals};
1414
use std::borrow::Cow;
1515
use std::fmt::Debug;

0 commit comments

Comments
 (0)