Skip to main content

engage/generated/moon_sharp/interpreter/tree/expressions/
symbolrefexpression.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::{
9        moon_sharp::interpreter::tree::{
10            expression::{Expression, IExpression},
11            nodebase::{INodeBase, NodeBase},
12        },
13        system::object::{IObject, Object},
14    };
15
16    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/moon_sharp/interpreter/tree/expressions/symbolrefexpression/SymbolRefExpression.md"))]
17    #[::unity::class(namespace = "MoonSharp.Interpreter.Tree.Expressions", name = "SymbolRefExpression")]
18    #[parent(crate::moon_sharp::interpreter::tree::expression::Expression)]
19    pub struct SymbolRefExpression {
20        #[offset(32)]
21        #[rename(name = "m_Ref")]
22        pub m_ref: crate::moon_sharp::interpreter::symbolref::SymbolRef,
23        #[offset(40)]
24        #[rename(name = "m_VarName")]
25        pub m_var_name: ::unity::Il2CppString,
26    }
27}
28
29#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression-types")]
30pub use __types::*;
31
32#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
33#[doc(hidden)]
34#[allow(non_snake_case, non_camel_case_types, clippy::too_many_arguments)]
35mod __SymbolRefExpression_unity_raw {
36    use super::*;
37    #[doc(hidden)]
38    #[allow(non_snake_case)]
39    pub mod __lookup_ctor {
40        use super::*;
41        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
42            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
43                <crate::moon_sharp::interpreter::tree::token::Token as ::unity::IlType>::il_type(),
44                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
45            ];
46            ::unity::lookup::method_info_on_class_with_signature(
47                <SymbolRefExpression as ::unity::ClassIdentity>::class(),
48                ".ctor",
49                2,
50                param_types,
51                false,
52            )
53        });
54        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
55            match &*METHOD {
56                ::core::result::Result::Ok(mi) => *mi,
57                ::core::result::Result::Err(e) => {
58                    panic!(
59                        "method lookup failed: {}
60::{}
61: {}
62",
63                        <SymbolRefExpression as ::unity::ClassIdentity>::NAME,
64                        ".ctor",
65                        e
66                    )
67                },
68            }
69        }
70    }
71    #[doc(hidden)]
72    #[allow(non_snake_case)]
73    pub mod __lookup_ctor_2 {
74        use super::*;
75        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
76            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
77                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
78                <crate::moon_sharp::interpreter::symbolref::SymbolRef as ::unity::IlType>::il_type(),
79            ];
80            ::unity::lookup::method_info_on_class_with_signature(
81                <SymbolRefExpression as ::unity::ClassIdentity>::class(),
82                ".ctor",
83                2,
84                param_types,
85                false,
86            )
87        });
88        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
89            match &*METHOD {
90                ::core::result::Result::Ok(mi) => *mi,
91                ::core::result::Result::Err(e) => {
92                    panic!(
93                        "method lookup failed: {}
94::{}
95: {}
96",
97                        <SymbolRefExpression as ::unity::ClassIdentity>::NAME,
98                        ".ctor",
99                        e
100                    )
101                },
102            }
103        }
104    }
105}
106
107#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
108pub trait ISymbolRefExpressionMethods: ISymbolRefExpression {
109    #[doc = "`.ctor(crate::moon_sharp::interpreter::tree::token::Token, crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)` overload"]
110    fn ctor(
111        self,
112        t: impl ::core::convert::Into<crate::moon_sharp::interpreter::tree::token::Token>,
113        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
114    ) -> () {
115        unsafe {
116            let __receiver = <SymbolRefExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
117            ::unity::il2cpp_call!(__SymbolRefExpression_unity_raw::__lookup_ctor::get_method_info().method_ptr,();
118(SymbolRefExpression)__receiver,(crate::moon_sharp::interpreter::tree::token::Token)::core::convert::Into::into(t),(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext))
119        }
120    }
121    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, crate::moon_sharp::interpreter::symbolref::SymbolRef)` overload"]
122    fn ctor_2(
123        self,
124        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
125        refr: impl ::core::convert::Into<crate::moon_sharp::interpreter::symbolref::SymbolRef>,
126    ) -> () {
127        unsafe {
128            let __receiver = <SymbolRefExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
129            ::unity::il2cpp_call!(__SymbolRefExpression_unity_raw::__lookup_ctor_2::get_method_info().method_ptr,();
130(SymbolRefExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext),(crate::moon_sharp::interpreter::symbolref::SymbolRef)::core::convert::Into::into(refr))
131        }
132    }
133    #[doc = "`Compile(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode)` overload"]
134    fn compile(self, bc: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode>) -> () {
135        unsafe {
136            let __receiver = <SymbolRefExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
137            {
138                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
139                let __vi = *__vt.get(4usize).unwrap_or_else(|| {
140                    panic!(
141                        "unity: virtual slot {}
142 out of range (vtable len {}
143) on the runtime class behind {}
144 (method `{}
145`)",
146                        4usize,
147                        __vt.len(),
148                        <SymbolRefExpression as ::unity::ClassIdentity>::NAME,
149                        "Compile",
150                    )
151                });
152                let __inner: extern "C" fn(
153                    SymbolRefExpression,
154                    crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
155                    ::unity::OptionalMethod,
156                ) -> () = ::core::mem::transmute(__vi.method_ptr);
157                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
158                __inner(__receiver, ::core::convert::Into::into(bc), __mi)
159            }
160        }
161    }
162    #[doc = "`CompileAssignment(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode, i32, i32)` overload"]
163    fn compile_assignment(
164        self,
165        bc: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode>,
166        stackofs: impl ::core::convert::Into<i32>,
167        tupleidx: impl ::core::convert::Into<i32>,
168    ) -> () {
169        unsafe {
170            let __receiver = <SymbolRefExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
171            {
172                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
173                let __vi = *__vt.get(8usize).unwrap_or_else(|| {
174                    panic!(
175                        "unity: virtual slot {}
176 out of range (vtable len {}
177) on the runtime class behind {}
178 (method `{}
179`)",
180                        8usize,
181                        __vt.len(),
182                        <SymbolRefExpression as ::unity::ClassIdentity>::NAME,
183                        "CompileAssignment",
184                    )
185                });
186                let __inner: extern "C" fn(
187                    SymbolRefExpression,
188                    crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
189                    i32,
190                    i32,
191                    ::unity::OptionalMethod,
192                ) -> () = ::core::mem::transmute(__vi.method_ptr);
193                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
194                __inner(
195                    __receiver,
196                    ::core::convert::Into::into(bc),
197                    ::core::convert::Into::into(stackofs),
198                    ::core::convert::Into::into(tupleidx),
199                    __mi,
200                )
201            }
202        }
203    }
204    #[doc = "`Eval(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)` overload"]
205    fn eval(
206        self,
207        context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
208    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
209        unsafe {
210            let __receiver = <SymbolRefExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
211            {
212                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
213                let __vi = *__vt.get(6usize).unwrap_or_else(|| {
214                    panic!(
215                        "unity: virtual slot {}
216 out of range (vtable len {}
217) on the runtime class behind {}
218 (method `{}
219`)",
220                        6usize,
221                        __vt.len(),
222                        <SymbolRefExpression as ::unity::ClassIdentity>::NAME,
223                        "Eval",
224                    )
225                });
226                let __inner: extern "C" fn(
227                    SymbolRefExpression,
228                    crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
229                    ::unity::OptionalMethod,
230                ) -> crate::moon_sharp::interpreter::dynvalue::DynValue = ::core::mem::transmute(__vi.method_ptr);
231                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
232                __inner(__receiver, ::core::convert::Into::into(context), __mi)
233            }
234        }
235    }
236    #[doc = "`FindDynamic(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)` overload"]
237    fn find_dynamic(
238        self,
239        context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
240    ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef {
241        unsafe {
242            let __receiver = <SymbolRefExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
243            {
244                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
245                let __vi = *__vt.get(7usize).unwrap_or_else(|| {
246                    panic!(
247                        "unity: virtual slot {}
248 out of range (vtable len {}
249) on the runtime class behind {}
250 (method `{}
251`)",
252                        7usize,
253                        __vt.len(),
254                        <SymbolRefExpression as ::unity::ClassIdentity>::NAME,
255                        "FindDynamic",
256                    )
257                });
258                let __inner: extern "C" fn(
259                    SymbolRefExpression,
260                    crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
261                    ::unity::OptionalMethod,
262                ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef = ::core::mem::transmute(__vi.method_ptr);
263                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
264                __inner(__receiver, ::core::convert::Into::into(context), __mi)
265            }
266        }
267    }
268}
269
270#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
271impl<__T: ISymbolRefExpression> ISymbolRefExpressionMethods for __T {}
272
273#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
274impl SymbolRefExpression {
275    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
276        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
277    }
278
279    pub fn ctor_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
280        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
281    }
282
283    pub fn compile_method_info() -> &'static ::unity::il2cpp::MethodInfo {
284        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
285    }
286
287    pub fn compile_assignment_method_info() -> &'static ::unity::il2cpp::MethodInfo {
288        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
289    }
290
291    pub fn eval_method_info() -> &'static ::unity::il2cpp::MethodInfo {
292        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
293    }
294
295    pub fn find_dynamic_method_info() -> &'static ::unity::il2cpp::MethodInfo {
296        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
297    }
298}
299
300#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
301impl SymbolRefExpression {
302    #[doc = "Direct (non-virtual) call to `SymbolRefExpression`'s own `Compile`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
303    pub unsafe fn compile(
304        this: impl ::core::convert::Into<::unity::IlInstance>,
305        bc: crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
306    ) -> () {
307        let __mi = Self::compile_method_info();
308        let __inner: extern "C" fn(
309            ::unity::IlInstance,
310            crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
311            ::unity::OptionalMethod,
312        ) -> () = ::core::mem::transmute(__mi.method_ptr);
313        __inner(this.into(), bc, ::core::option::Option::None)
314    }
315
316    #[doc = "Direct (non-virtual) call to `SymbolRefExpression`'s own `CompileAssignment`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
317    pub unsafe fn compile_assignment(
318        this: impl ::core::convert::Into<::unity::IlInstance>,
319        bc: crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
320        stackofs: i32,
321        tupleidx: i32,
322    ) -> () {
323        let __mi = Self::compile_assignment_method_info();
324        let __inner: extern "C" fn(
325            ::unity::IlInstance,
326            crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
327            i32,
328            i32,
329            ::unity::OptionalMethod,
330        ) -> () = ::core::mem::transmute(__mi.method_ptr);
331        __inner(this.into(), bc, stackofs, tupleidx, ::core::option::Option::None)
332    }
333
334    #[doc = "Direct (non-virtual) call to `SymbolRefExpression`'s own `Eval`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
335    pub unsafe fn eval(
336        this: impl ::core::convert::Into<::unity::IlInstance>,
337        context: crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
338    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
339        let __mi = Self::eval_method_info();
340        let __inner: extern "C" fn(
341            ::unity::IlInstance,
342            crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
343            ::unity::OptionalMethod,
344        ) -> crate::moon_sharp::interpreter::dynvalue::DynValue = ::core::mem::transmute(__mi.method_ptr);
345        __inner(this.into(), context, ::core::option::Option::None)
346    }
347
348    #[doc = "Direct (non-virtual) call to `SymbolRefExpression`'s own `FindDynamic`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
349    pub unsafe fn find_dynamic(
350        this: impl ::core::convert::Into<::unity::IlInstance>,
351        context: crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
352    ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef {
353        let __mi = Self::find_dynamic_method_info();
354        let __inner: extern "C" fn(
355            ::unity::IlInstance,
356            crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
357            ::unity::OptionalMethod,
358        ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef = ::core::mem::transmute(__mi.method_ptr);
359        __inner(this.into(), context, ::core::option::Option::None)
360    }
361}
362
363#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
364impl SymbolRefExpression {
365    #[doc = "`.ctor(crate::moon_sharp::interpreter::tree::token::Token, crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)` — overload selector"]
366    pub fn new(
367        t: crate::moon_sharp::interpreter::tree::token::Token,
368        lcontext: crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext,
369    ) -> Self {
370        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
371            panic!(
372                "{}
373::{}
374 failed to instantiate",
375                ::core::stringify!(SymbolRefExpression),
376                ::core::stringify!(new),
377            )
378        });
379        <Self as ISymbolRefExpressionMethods>::ctor(this, t, lcontext);
380        this
381    }
382
383    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, crate::moon_sharp::interpreter::symbolref::SymbolRef)` — overload selector"]
384    pub fn new_2(
385        lcontext: crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext,
386        refr: crate::moon_sharp::interpreter::symbolref::SymbolRef,
387    ) -> Self {
388        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
389            panic!(
390                "{}
391::{}
392 failed to instantiate",
393                ::core::stringify!(SymbolRefExpression),
394                ::core::stringify!(new_2),
395            )
396        });
397        <Self as ISymbolRefExpressionMethods>::ctor_2(this, lcontext, refr);
398        this
399    }
400}
401
402#[cfg(feature = "moon_sharp-interpreter-tree-expressions-symbolrefexpression")]
403#[doc(hidden)]
404pub mod prelude {
405    pub use super::{ISymbolRefExpression, ISymbolRefExpressionMethods, SymbolRefExpression};
406    #[cfg(feature = "moon_sharp-interpreter-tree-expression")]
407    pub use crate::moon_sharp::interpreter::tree::expression::IExpressionMethods;
408    #[cfg(feature = "moon_sharp-interpreter-tree-nodebase")]
409    pub use crate::moon_sharp::interpreter::tree::nodebase::INodeBaseMethods;
410    #[cfg(feature = "system-object")]
411    pub use crate::system::object::IObjectMethods;
412    pub use crate::{
413        moon_sharp::interpreter::tree::{expression::IExpression, nodebase::INodeBase},
414        system::object::IObject,
415    };
416}