Skip to main content

engage/generated/moon_sharp/interpreter/execution/
iloop.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "moon_sharp-interpreter-execution-iloop-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8
9    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/moon_sharp/interpreter/execution/iloop/ILoop.md"))]
10    #[::unity::class(namespace = "MoonSharp.Interpreter.Execution", name = "ILoop")]
11    pub struct ILoop {}
12}
13
14#[cfg(feature = "moon_sharp-interpreter-execution-iloop-types")]
15pub use __types::*;
16
17#[cfg(feature = "moon_sharp-interpreter-execution-iloop")]
18pub trait IILoopMethods: IILoop {
19    #[doc = "`CompileBreak(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode)` overload"]
20    fn compile_break(self, bc: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode>) -> () {
21        unsafe {
22            let __receiver = <ILoop as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
23            {
24                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
25                let __vi = *__vt.get(0usize).unwrap_or_else(|| {
26                    panic!(
27                        "unity: virtual slot {}
28 out of range (vtable len {}
29) on the runtime class behind {}
30 (method `{}
31`)",
32                        0usize,
33                        __vt.len(),
34                        <ILoop as ::unity::ClassIdentity>::NAME,
35                        "CompileBreak",
36                    )
37                });
38                let __inner: extern "C" fn(ILoop, crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode, ::unity::OptionalMethod) -> () =
39                    ::core::mem::transmute(__vi.method_ptr);
40                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
41                __inner(__receiver, ::core::convert::Into::into(bc), __mi)
42            }
43        }
44    }
45    #[doc = "`IsBoundary()` overload"]
46    fn is_boundary(self) -> bool {
47        unsafe {
48            let __receiver = <ILoop as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
49            {
50                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
51                let __vi = *__vt.get(1usize).unwrap_or_else(|| {
52                    panic!(
53                        "unity: virtual slot {}
54 out of range (vtable len {}
55) on the runtime class behind {}
56 (method `{}
57`)",
58                        1usize,
59                        __vt.len(),
60                        <ILoop as ::unity::ClassIdentity>::NAME,
61                        "IsBoundary",
62                    )
63                });
64                let __inner: extern "C" fn(ILoop, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
65                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
66                __inner(__receiver, __mi)
67            }
68        }
69    }
70}
71
72#[cfg(feature = "moon_sharp-interpreter-execution-iloop")]
73impl<__T: IILoop> IILoopMethods for __T {}
74
75#[cfg(feature = "moon_sharp-interpreter-execution-iloop")]
76impl ILoop {
77    pub fn compile_break_method_info() -> &'static ::unity::il2cpp::MethodInfo {
78        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
79    }
80
81    pub fn is_boundary_method_info() -> &'static ::unity::il2cpp::MethodInfo {
82        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
83    }
84}
85
86#[cfg(feature = "moon_sharp-interpreter-execution-iloop")]
87impl ILoop {
88    #[doc = "Direct (non-virtual) call to `ILoop`'s own `CompileBreak`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
89    pub unsafe fn compile_break(
90        this: impl ::core::convert::Into<::unity::IlInstance>,
91        bc: crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
92    ) -> () {
93        let __mi = Self::compile_break_method_info();
94        let __inner: extern "C" fn(
95            ::unity::IlInstance,
96            crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
97            ::unity::OptionalMethod,
98        ) -> () = ::core::mem::transmute(__mi.method_ptr);
99        __inner(this.into(), bc, ::core::option::Option::None)
100    }
101
102    #[doc = "Direct (non-virtual) call to `ILoop`'s own `IsBoundary`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
103    pub unsafe fn is_boundary(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
104        let __mi = Self::is_boundary_method_info();
105        let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
106        __inner(this.into(), ::core::option::Option::None)
107    }
108}
109
110#[cfg(feature = "moon_sharp-interpreter-execution-iloop")]
111#[doc(hidden)]
112pub mod prelude {
113    pub use super::{IILoop, IILoopMethods, ILoop};
114}