Skip to main content

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

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression-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/functiondefinitionexpression/FunctionDefinitionExpression.md"))]
17    #[::unity::class(namespace = "MoonSharp.Interpreter.Tree.Expressions", name = "FunctionDefinitionExpression")]
18    #[parent(crate::moon_sharp::interpreter::tree::expression::Expression)]
19    pub struct FunctionDefinitionExpression {
20        #[offset(32)]
21        #[rename(name = "m_ParamNames")]
22        pub m_param_names: ::unity::Array<crate::moon_sharp::interpreter::symbolref::SymbolRef>,
23        #[offset(40)]
24        #[rename(name = "m_Statement")]
25        pub m_statement: crate::moon_sharp::interpreter::tree::statement::Statement,
26        #[offset(48)]
27        #[rename(name = "m_StackFrame")]
28        pub m_stack_frame: crate::moon_sharp::interpreter::execution::runtimescopeframe::RuntimeScopeFrame,
29        #[offset(56)]
30        #[rename(name = "m_Closure")]
31        pub m_closure: crate::system::collections::generic::list_1::List_1<crate::moon_sharp::interpreter::symbolref::SymbolRef>,
32        #[offset(64)]
33        #[rename(name = "m_HasVarArgs")]
34        pub m_has_var_args: bool,
35        #[offset(72)]
36        #[rename(name = "m_ClosureInstruction")]
37        pub m_closure_instruction: crate::moon_sharp::interpreter::execution::vm::instruction::Instruction,
38        #[offset(80)]
39        #[rename(name = "m_UsesGlobalEnv")]
40        pub m_uses_global_env: bool,
41        #[offset(88)]
42        #[rename(name = "m_Env")]
43        pub m_env: crate::moon_sharp::interpreter::symbolref::SymbolRef,
44        #[offset(96)]
45        #[rename(name = "m_Begin")]
46        pub m_begin: crate::moon_sharp::interpreter::debugging::sourceref::SourceRef,
47        #[offset(104)]
48        #[rename(name = "m_End")]
49        pub m_end: crate::moon_sharp::interpreter::debugging::sourceref::SourceRef,
50    }
51}
52
53#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression-types")]
54pub use __types::*;
55
56#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
57#[doc(hidden)]
58#[allow(non_snake_case, non_camel_case_types, clippy::too_many_arguments)]
59mod __FunctionDefinitionExpression_unity_raw {
60    use super::*;
61    #[doc(hidden)]
62    #[allow(non_snake_case)]
63    pub mod __lookup_ctor {
64        use super::*;
65        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
66            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
67                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
68                <bool as ::unity::IlType>::il_type(),
69            ];
70            ::unity::lookup::method_info_on_class_with_signature(
71                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
72                ".ctor",
73                2,
74                param_types,
75                false,
76            )
77        });
78        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
79            match &*METHOD {
80                ::core::result::Result::Ok(mi) => *mi,
81                ::core::result::Result::Err(e) => {
82                    panic!(
83                        "method lookup failed: {}
84::{}
85: {}
86",
87                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
88                        ".ctor",
89                        e
90                    )
91                },
92            }
93        }
94    }
95    #[doc(hidden)]
96    #[allow(non_snake_case)]
97    pub mod __lookup_ctor_2 {
98        use super::*;
99        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
100            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
101                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
102                <bool as ::unity::IlType>::il_type(),
103                <bool as ::unity::IlType>::il_type(),
104            ];
105            ::unity::lookup::method_info_on_class_with_signature(
106                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
107                ".ctor",
108                3,
109                param_types,
110                false,
111            )
112        });
113        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
114            match &*METHOD {
115                ::core::result::Result::Ok(mi) => *mi,
116                ::core::result::Result::Err(e) => {
117                    panic!(
118                        "method lookup failed: {}
119::{}
120: {}
121",
122                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
123                        ".ctor",
124                        e
125                    )
126                },
127            }
128        }
129    }
130    #[doc(hidden)]
131    #[allow(non_snake_case)]
132    pub mod __lookup_ctor_3 {
133        use super::*;
134        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
135            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
136                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
137                <bool as ::unity::IlType>::il_type(),
138                <bool as ::unity::IlType>::il_type(),
139                <bool as ::unity::IlType>::il_type(),
140            ];
141            ::unity::lookup::method_info_on_class_with_signature(
142                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
143                ".ctor",
144                4,
145                param_types,
146                false,
147            )
148        });
149        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
150            match &*METHOD {
151                ::core::result::Result::Ok(mi) => *mi,
152                ::core::result::Result::Err(e) => {
153                    panic!(
154                        "method lookup failed: {}
155::{}
156: {}
157",
158                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
159                        ".ctor",
160                        e
161                    )
162                },
163            }
164        }
165    }
166    #[doc(hidden)]
167    #[allow(non_snake_case)]
168    pub mod __lookup_create_lambda_body {
169        use super::*;
170        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
171            let param_types: &[&'static ::unity::il2cpp::Il2CppType] =
172                &[<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type()];
173            ::unity::lookup::method_info_on_class_with_signature(
174                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
175                "CreateLambdaBody",
176                1,
177                param_types,
178                false,
179            )
180        });
181        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
182            match &*METHOD {
183                ::core::result::Result::Ok(mi) => *mi,
184                ::core::result::Result::Err(e) => {
185                    panic!(
186                        "method lookup failed: {}
187::{}
188: {}
189",
190                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
191                        "CreateLambdaBody",
192                        e
193                    )
194                },
195            }
196        }
197    }
198    #[doc(hidden)]
199    #[allow(non_snake_case)]
200    pub mod __lookup_create_body {
201        use super::*;
202        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
203            let param_types: &[&'static ::unity::il2cpp::Il2CppType] =
204                &[<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type()];
205            ::unity::lookup::method_info_on_class_with_signature(
206                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
207                "CreateBody",
208                1,
209                param_types,
210                false,
211            )
212        });
213        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
214            match &*METHOD {
215                ::core::result::Result::Ok(mi) => *mi,
216                ::core::result::Result::Err(e) => {
217                    panic!(
218                        "method lookup failed: {}
219::{}
220: {}
221",
222                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
223                        "CreateBody",
224                        e
225                    )
226                },
227            }
228        }
229    }
230    #[doc(hidden)]
231    #[allow(non_snake_case)]
232    pub mod __lookup_build_param_list {
233        use super::*;
234        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
235            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
236                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
237                <bool as ::unity::IlType>::il_type(),
238                <crate::moon_sharp::interpreter::tree::token::Token as ::unity::IlType>::il_type(),
239                <bool as ::unity::IlType>::il_type(),
240            ];
241            ::unity::lookup::method_info_on_class_with_signature(
242                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
243                "BuildParamList",
244                4,
245                param_types,
246                false,
247            )
248        });
249        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
250            match &*METHOD {
251                ::core::result::Result::Ok(mi) => *mi,
252                ::core::result::Result::Err(e) => {
253                    panic!(
254                        "method lookup failed: {}
255::{}
256: {}
257",
258                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
259                        "BuildParamList",
260                        e
261                    )
262                },
263            }
264        }
265    }
266    #[doc(hidden)]
267    #[allow(non_snake_case)]
268    pub mod __lookup_define_arguments {
269        use super::*;
270        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
271            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
272                <crate::system::collections::generic::list_1::List_1<::unity::Il2CppString> as ::unity::IlType>::il_type(),
273                <crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext as ::unity::IlType>::il_type(),
274            ];
275            ::unity::lookup::method_info_on_class_with_signature(
276                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
277                "DefineArguments",
278                2,
279                param_types,
280                false,
281            )
282        });
283        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
284            match &*METHOD {
285                ::core::result::Result::Ok(mi) => *mi,
286                ::core::result::Result::Err(e) => {
287                    panic!(
288                        "method lookup failed: {}
289::{}
290: {}
291",
292                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
293                        "DefineArguments",
294                        e
295                    )
296                },
297            }
298        }
299    }
300    #[doc(hidden)]
301    #[allow(non_snake_case)]
302    pub mod __lookup_compile_body {
303        use super::*;
304        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
305            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
306                <crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode as ::unity::IlType>::il_type(),
307                <::unity::Il2CppString as ::unity::IlType>::il_type(),
308            ];
309            ::unity::lookup::method_info_on_class_with_signature(
310                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
311                "CompileBody",
312                2,
313                param_types,
314                false,
315            )
316        });
317        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
318            match &*METHOD {
319                ::core::result::Result::Ok(mi) => *mi,
320                ::core::result::Result::Err(e) => {
321                    panic!(
322                        "method lookup failed: {}
323::{}
324: {}
325",
326                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
327                        "CompileBody",
328                        e
329                    )
330                },
331            }
332        }
333    }
334    #[doc(hidden)]
335    #[allow(non_snake_case)]
336    pub mod __lookup_compile {
337        use super::*;
338        static METHOD: ::std::sync::LazyLock<::unity::Il2CppResult<&'static ::unity::il2cpp::MethodInfo>> = ::std::sync::LazyLock::new(|| {
339            let param_types: &[&'static ::unity::il2cpp::Il2CppType] = &[
340                <crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode as ::unity::IlType>::il_type(),
341                <crate::system::func_1::Func_1<i32> as ::unity::IlType>::il_type(),
342                <::unity::Il2CppString as ::unity::IlType>::il_type(),
343            ];
344            ::unity::lookup::method_info_on_class_with_signature(
345                <FunctionDefinitionExpression as ::unity::ClassIdentity>::class(),
346                "Compile",
347                3,
348                param_types,
349                false,
350            )
351        });
352        pub fn get_method_info() -> &'static ::unity::il2cpp::MethodInfo {
353            match &*METHOD {
354                ::core::result::Result::Ok(mi) => *mi,
355                ::core::result::Result::Err(e) => {
356                    panic!(
357                        "method lookup failed: {}
358::{}
359: {}
360",
361                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
362                        "Compile",
363                        e
364                    )
365                },
366            }
367        }
368    }
369}
370
371#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
372pub trait IFunctionDefinitionExpressionMethods: IFunctionDefinitionExpression {
373    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool)` overload"]
374    fn ctor(
375        self,
376        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
377        uses_global_env: impl ::core::convert::Into<bool>,
378    ) -> () {
379        unsafe {
380            let __receiver =
381                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
382            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_ctor::get_method_info().method_ptr,();
383(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext),(bool)::core::convert::Into::into(uses_global_env))
384        }
385    }
386    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool, bool)` overload"]
387    fn ctor_2(
388        self,
389        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
390        push_self_param: impl ::core::convert::Into<bool>,
391        is_lambda: impl ::core::convert::Into<bool>,
392    ) -> () {
393        unsafe {
394            let __receiver =
395                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
396            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_ctor_2::get_method_info().method_ptr,();
397(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext),(bool)::core::convert::Into::into(push_self_param),(bool)::core::convert::Into::into(is_lambda))
398        }
399    }
400    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool, bool, bool)` overload"]
401    fn ctor_3(
402        self,
403        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
404        push_self_param: impl ::core::convert::Into<bool>,
405        uses_global_env: impl ::core::convert::Into<bool>,
406        is_lambda: impl ::core::convert::Into<bool>,
407    ) -> () {
408        unsafe {
409            let __receiver =
410                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
411            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_ctor_3::get_method_info().method_ptr,();
412(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext),(bool)::core::convert::Into::into(push_self_param),(bool)::core::convert::Into::into(uses_global_env),(bool)::core::convert::Into::into(is_lambda))
413        }
414    }
415    #[doc = "`CreateLambdaBody(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)` overload"]
416    fn create_lambda_body(
417        self,
418        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
419    ) -> crate::moon_sharp::interpreter::tree::statement::Statement {
420        unsafe {
421            let __receiver =
422                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
423            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_create_lambda_body::get_method_info().method_ptr,crate::moon_sharp::interpreter::tree::statement::Statement;
424(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext))
425        }
426    }
427    #[doc = "`CreateBody(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)` overload"]
428    fn create_body(
429        self,
430        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
431    ) -> crate::moon_sharp::interpreter::tree::statement::Statement {
432        unsafe {
433            let __receiver =
434                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
435            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_create_body::get_method_info().method_ptr,crate::moon_sharp::interpreter::tree::statement::Statement;
436(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext))
437        }
438    }
439    #[doc = "`BuildParamList(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool, crate::moon_sharp::interpreter::tree::token::Token, bool)` overload"]
440    fn build_param_list(
441        self,
442        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
443        push_self_param: impl ::core::convert::Into<bool>,
444        open_bracket_token: impl ::core::convert::Into<crate::moon_sharp::interpreter::tree::token::Token>,
445        is_lambda: impl ::core::convert::Into<bool>,
446    ) -> crate::system::collections::generic::list_1::List_1<::unity::Il2CppString> {
447        unsafe {
448            let __receiver =
449                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
450            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_build_param_list::get_method_info().method_ptr,crate::system::collections::generic::list_1::List_1< ::unity::Il2CppString> ;
451(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext),(bool)::core::convert::Into::into(push_self_param),(crate::moon_sharp::interpreter::tree::token::Token)::core::convert::Into::into(open_bracket_token),(bool)::core::convert::Into::into(is_lambda))
452        }
453    }
454    #[doc = "`DefineArguments(crate::system::collections::generic::list_1::List_1<::unity::Il2CppString>, crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)` overload"]
455    fn define_arguments(
456        self,
457        paramnames: impl ::core::convert::Into<crate::system::collections::generic::list_1::List_1<::unity::Il2CppString>>,
458        lcontext: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext>,
459    ) -> ::unity::Array<crate::moon_sharp::interpreter::symbolref::SymbolRef> {
460        unsafe {
461            let __receiver =
462                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
463            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_define_arguments::get_method_info().method_ptr, ::unity::Array<crate::moon_sharp::interpreter::symbolref::SymbolRef> ;
464(FunctionDefinitionExpression)__receiver,(crate::system::collections::generic::list_1::List_1< ::unity::Il2CppString>)::core::convert::Into::into(paramnames),(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext)::core::convert::Into::into(lcontext))
465        }
466    }
467    #[doc = "`CreateUpvalue(crate::moon_sharp::interpreter::execution::buildtimescope::BuildTimeScope, crate::moon_sharp::interpreter::symbolref::SymbolRef)` overload"]
468    fn create_upvalue(
469        self,
470        scope: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::buildtimescope::BuildTimeScope>,
471        symbol: impl ::core::convert::Into<crate::moon_sharp::interpreter::symbolref::SymbolRef>,
472    ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef {
473        unsafe {
474            let __receiver =
475                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
476            {
477                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
478                let __vi = *__vt.get(8usize).unwrap_or_else(|| {
479                    panic!(
480                        "unity: virtual slot {}
481 out of range (vtable len {}
482) on the runtime class behind {}
483 (method `{}
484`)",
485                        8usize,
486                        __vt.len(),
487                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
488                        "CreateUpvalue",
489                    )
490                });
491                let __inner: extern "C" fn(
492                    FunctionDefinitionExpression,
493                    crate::moon_sharp::interpreter::execution::buildtimescope::BuildTimeScope,
494                    crate::moon_sharp::interpreter::symbolref::SymbolRef,
495                    ::unity::OptionalMethod,
496                ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef = ::core::mem::transmute(__vi.method_ptr);
497                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
498                __inner(__receiver, ::core::convert::Into::into(scope), ::core::convert::Into::into(symbol), __mi)
499            }
500        }
501    }
502    #[doc = "`Eval(crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext)` overload"]
503    fn eval(
504        self,
505        context: impl ::core::convert::Into<crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext>,
506    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
507        unsafe {
508            let __receiver =
509                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
510            {
511                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
512                let __vi = *__vt.get(6usize).unwrap_or_else(|| {
513                    panic!(
514                        "unity: virtual slot {}
515 out of range (vtable len {}
516) on the runtime class behind {}
517 (method `{}
518`)",
519                        6usize,
520                        __vt.len(),
521                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
522                        "Eval",
523                    )
524                });
525                let __inner: extern "C" fn(
526                    FunctionDefinitionExpression,
527                    crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
528                    ::unity::OptionalMethod,
529                ) -> crate::moon_sharp::interpreter::dynvalue::DynValue = ::core::mem::transmute(__vi.method_ptr);
530                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
531                __inner(__receiver, ::core::convert::Into::into(context), __mi)
532            }
533        }
534    }
535    #[doc = "`CompileBody(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode, ::unity::Il2CppString)` overload"]
536    fn compile_body(
537        self,
538        bc: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode>,
539        friendly_name: impl ::core::convert::Into<::unity::Il2CppString>,
540    ) -> i32 {
541        unsafe {
542            let __receiver =
543                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
544            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_compile_body::get_method_info().method_ptr,i32;
545(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode)::core::convert::Into::into(bc),(::unity::Il2CppString)::core::convert::Into::into(friendly_name))
546        }
547    }
548    #[doc = "`Compile(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode, crate::system::func_1::Func_1<i32>, ::unity::Il2CppString)` overload"]
549    fn compile(
550        self,
551        bc: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode>,
552        after_decl: impl ::core::convert::Into<crate::system::func_1::Func_1<i32>>,
553        friendly_name: impl ::core::convert::Into<::unity::Il2CppString>,
554    ) -> i32 {
555        unsafe {
556            let __receiver =
557                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
558            ::unity::il2cpp_call!(__FunctionDefinitionExpression_unity_raw::__lookup_compile::get_method_info().method_ptr,i32;
559(FunctionDefinitionExpression)__receiver,(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode)::core::convert::Into::into(bc),(crate::system::func_1::Func_1<i32>)::core::convert::Into::into(after_decl),(::unity::Il2CppString)::core::convert::Into::into(friendly_name))
560        }
561    }
562    #[doc = "`Compile(crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode)` overload"]
563    fn compile_2(self, bc: impl ::core::convert::Into<crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode>) -> () {
564        unsafe {
565            let __receiver =
566                <FunctionDefinitionExpression as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
567            {
568                let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
569                let __vi = *__vt.get(4usize).unwrap_or_else(|| {
570                    panic!(
571                        "unity: virtual slot {}
572 out of range (vtable len {}
573) on the runtime class behind {}
574 (method `{}
575`)",
576                        4usize,
577                        __vt.len(),
578                        <FunctionDefinitionExpression as ::unity::ClassIdentity>::NAME,
579                        "Compile",
580                    )
581                });
582                let __inner: extern "C" fn(
583                    FunctionDefinitionExpression,
584                    crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
585                    ::unity::OptionalMethod,
586                ) -> () = ::core::mem::transmute(__vi.method_ptr);
587                let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
588                __inner(__receiver, ::core::convert::Into::into(bc), __mi)
589            }
590        }
591    }
592}
593
594#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
595impl<__T: IFunctionDefinitionExpression> IFunctionDefinitionExpressionMethods for __T {}
596
597#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
598impl FunctionDefinitionExpression {
599    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
600        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
601    }
602
603    pub fn ctor_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
604        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
605    }
606
607    pub fn ctor_3_method_info() -> &'static ::unity::il2cpp::MethodInfo {
608        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
609    }
610
611    pub fn create_lambda_body_method_info() -> &'static ::unity::il2cpp::MethodInfo {
612        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
613    }
614
615    pub fn create_body_method_info() -> &'static ::unity::il2cpp::MethodInfo {
616        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
617    }
618
619    pub fn build_param_list_method_info() -> &'static ::unity::il2cpp::MethodInfo {
620        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
621    }
622
623    pub fn define_arguments_method_info() -> &'static ::unity::il2cpp::MethodInfo {
624        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
625    }
626
627    pub fn create_upvalue_method_info() -> &'static ::unity::il2cpp::MethodInfo {
628        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[7]
629    }
630
631    pub fn eval_method_info() -> &'static ::unity::il2cpp::MethodInfo {
632        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[8]
633    }
634
635    pub fn compile_body_method_info() -> &'static ::unity::il2cpp::MethodInfo {
636        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[9]
637    }
638
639    pub fn compile_method_info() -> &'static ::unity::il2cpp::MethodInfo {
640        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[10]
641    }
642
643    pub fn compile_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
644        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[11]
645    }
646}
647
648#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
649impl FunctionDefinitionExpression {
650    #[doc = "Direct (non-virtual) call to `FunctionDefinitionExpression`'s own `CreateUpvalue`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
651    pub unsafe fn create_upvalue(
652        this: impl ::core::convert::Into<::unity::IlInstance>,
653        scope: crate::moon_sharp::interpreter::execution::buildtimescope::BuildTimeScope,
654        symbol: crate::moon_sharp::interpreter::symbolref::SymbolRef,
655    ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef {
656        let __mi = Self::create_upvalue_method_info();
657        let __inner: extern "C" fn(
658            ::unity::IlInstance,
659            crate::moon_sharp::interpreter::execution::buildtimescope::BuildTimeScope,
660            crate::moon_sharp::interpreter::symbolref::SymbolRef,
661            ::unity::OptionalMethod,
662        ) -> crate::moon_sharp::interpreter::symbolref::SymbolRef = ::core::mem::transmute(__mi.method_ptr);
663        __inner(this.into(), scope, symbol, ::core::option::Option::None)
664    }
665
666    #[doc = "Direct (non-virtual) call to `FunctionDefinitionExpression`'s own `Eval`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
667    pub unsafe fn eval(
668        this: impl ::core::convert::Into<::unity::IlInstance>,
669        context: crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
670    ) -> crate::moon_sharp::interpreter::dynvalue::DynValue {
671        let __mi = Self::eval_method_info();
672        let __inner: extern "C" fn(
673            ::unity::IlInstance,
674            crate::moon_sharp::interpreter::scriptexecutioncontext::ScriptExecutionContext,
675            ::unity::OptionalMethod,
676        ) -> crate::moon_sharp::interpreter::dynvalue::DynValue = ::core::mem::transmute(__mi.method_ptr);
677        __inner(this.into(), context, ::core::option::Option::None)
678    }
679
680    #[doc = "Direct (non-virtual) call to `FunctionDefinitionExpression`'s own `Compile`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
681    pub unsafe fn compile_2(
682        this: impl ::core::convert::Into<::unity::IlInstance>,
683        bc: crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
684    ) -> () {
685        let __mi = Self::compile_2_method_info();
686        let __inner: extern "C" fn(
687            ::unity::IlInstance,
688            crate::moon_sharp::interpreter::execution::vm::bytecode::ByteCode,
689            ::unity::OptionalMethod,
690        ) -> () = ::core::mem::transmute(__mi.method_ptr);
691        __inner(this.into(), bc, ::core::option::Option::None)
692    }
693}
694
695#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
696impl FunctionDefinitionExpression {
697    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool)` — overload selector"]
698    pub fn new(lcontext: crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, uses_global_env: bool) -> Self {
699        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
700            panic!(
701                "{}
702::{}
703 failed to instantiate",
704                ::core::stringify!(FunctionDefinitionExpression),
705                ::core::stringify!(new),
706            )
707        });
708        <Self as IFunctionDefinitionExpressionMethods>::ctor(this, lcontext, uses_global_env);
709        this
710    }
711
712    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool, bool)` — overload selector"]
713    pub fn new_2(
714        lcontext: crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext,
715        push_self_param: bool,
716        is_lambda: bool,
717    ) -> Self {
718        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
719            panic!(
720                "{}
721::{}
722 failed to instantiate",
723                ::core::stringify!(FunctionDefinitionExpression),
724                ::core::stringify!(new_2),
725            )
726        });
727        <Self as IFunctionDefinitionExpressionMethods>::ctor_2(this, lcontext, push_self_param, is_lambda);
728        this
729    }
730
731    #[doc = "`.ctor(crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext, bool, bool, bool)` — overload selector"]
732    pub fn new_3(
733        lcontext: crate::moon_sharp::interpreter::execution::scriptloadingcontext::ScriptLoadingContext,
734        push_self_param: bool,
735        uses_global_env: bool,
736        is_lambda: bool,
737    ) -> Self {
738        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
739            panic!(
740                "{}
741::{}
742 failed to instantiate",
743                ::core::stringify!(FunctionDefinitionExpression),
744                ::core::stringify!(new_3),
745            )
746        });
747        <Self as IFunctionDefinitionExpressionMethods>::ctor_3(this, lcontext, push_self_param, uses_global_env, is_lambda);
748        this
749    }
750}
751
752#[cfg(feature = "moon_sharp-interpreter-tree-expressions-functiondefinitionexpression")]
753#[doc(hidden)]
754pub mod prelude {
755    pub use super::{FunctionDefinitionExpression, IFunctionDefinitionExpression, IFunctionDefinitionExpressionMethods};
756    #[cfg(feature = "moon_sharp-interpreter-tree-expression")]
757    pub use crate::moon_sharp::interpreter::tree::expression::IExpressionMethods;
758    #[cfg(feature = "moon_sharp-interpreter-tree-nodebase")]
759    pub use crate::moon_sharp::interpreter::tree::nodebase::INodeBaseMethods;
760    #[cfg(feature = "system-object")]
761    pub use crate::system::object::IObjectMethods;
762    pub use crate::{
763        moon_sharp::interpreter::tree::{expression::IExpression, nodebase::INodeBase},
764        system::object::IObject,
765    };
766}