3ds Max C++ API Reference
Loading...
Searching...
No Matches
value_locals.h File Reference

Classes

class  MXS_Exit_ValueLocal_Scope
 Class that uses the RAII idiom to push/pop the thread local current_locals_frame. More...
class  MXS_Exit_ValueLocalArray_Scope
 Class that uses the RAII idiom to push/pop the thread local current_locals_frame. More...
class  ScopedValueTempArray
 Class that uses the RAII idiom to allocate and deallocate value temp arrays. More...
class  ScopedSaveCurrentFrames
 Class that uses the RAII idiom to save and restore the current frame data. More...
class  ScopedMaxScriptSEHandler
 Class that uses the RAII idiom to push/pop setting a structured error handler. More...
class  ScopedMaxScriptEvaluationContext
 Class that uses the RAII idiom to create a maxscript visible stack frame. More...
class  ScopedPushControl
 Class that uses the RAII idiom to push/pop the thread local current_controller. More...

Macros

#define one_value_local(n1)
#define one_value_local_noFrameValidate(n1)
#define one_typed_value_local(n1)
#define one_typed_value_local_noFrameValidate(n1)
#define two_value_locals(n1, n2)
#define two_typed_value_locals(n1, n2)
#define three_value_locals(n1, n2, n3)
#define three_typed_value_locals(n1, n2, n3)
#define four_value_locals(n1, n2, n3, n4)
#define four_typed_value_locals(n1, n2, n3, n4)
#define five_value_locals(n1, n2, n3, n4, n5)
#define five_typed_value_locals(n1, n2, n3, n4, n5)
#define six_value_locals(n1, n2, n3, n4, n5, n6)
#define six_typed_value_locals(n1, n2, n3, n4, n5, n6)
#define seven_value_locals(n1, n2, n3, n4, n5, n6, n7)
#define seven_typed_value_locals(n1, n2, n3, n4, n5, n6, n7)
#define eight_value_locals(n1, n2, n3, n4, n5, n6, n7, n8)
#define eight_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8)
#define nine_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9)
#define nine_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9)
#define ten_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10)
#define ten_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10)
#define eleven_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11)
#define eleven_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11)
#define twelve_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12)
#define twelve_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12)
#define thirteen_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13)
#define thirteen_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13)
#define fourteen_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14)
#define fourteen_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14)
#define value_local_array(var, count)
#define one_value_local_tls(n1)
#define one_value_local_noFrameValidate_tls(n1)
#define one_typed_value_local_tls(n1)
#define one_typed_value_local_noFrameValidate_tls(n1)
#define two_value_locals_tls(n1, n2)
#define two_typed_value_locals_tls(n1, n2)
#define three_value_locals_tls(n1, n2, n3)
#define three_typed_value_locals_tls(n1, n2, n3)
#define four_value_locals_tls(n1, n2, n3, n4)
#define four_typed_value_locals_tls(n1, n2, n3, n4)
#define five_value_locals_tls(n1, n2, n3, n4, n5)
#define five_typed_value_locals_tls(n1, n2, n3, n4, n5)
#define six_value_locals_tls(n1, n2, n3, n4, n5, n6)
#define six_typed_value_locals_tls(n1, n2, n3, n4, n5, n6)
#define seven_value_locals_tls(n1, n2, n3, n4, n5, n6, n7)
#define seven_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7)
#define eight_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8)
#define eight_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8)
#define nine_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9)
#define nine_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9)
#define ten_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10)
#define ten_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10)
#define eleven_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11)
#define eleven_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11)
#define twelve_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12)
#define twelve_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12)
#define thirteen_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13)
#define thirteen_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13)
#define fourteen_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14)
#define fourteen_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14)
#define value_local_array_tls(var, count)
#define return_value(r)
#define return_value_tls(r)
#define save_current_source()
#define restore_current_source()
#define save_current_source_no_pos()
#define restore_current_source_no_pos()
#define save_current_source_pos()
#define restore_current_source_pos()
#define save_current_source_to_frame()
#define save_current_source_to_frame_no_pos()
#define save_current_source_to_frame_pos()
#define save_current_source_to_frame_no_file()
#define save_current_source_tls()
#define restore_current_source_tls()
#define save_current_source_no_pos_tls()
#define restore_current_source_no_pos_tls()
#define save_current_source_pos_tls()
#define restore_current_source_pos_tls()
#define save_current_source_to_frame_tls()
#define save_current_source_to_frame_no_pos_tls()
#define save_current_source_to_frame_pos_tls()
#define save_current_source_to_frame_no_file_tls()

Functions

template<typename Type>
Type templated_return_value_fn (Type r)
template<typename Type>
Type templated_return_value_fn_tls (Type r, MAXScript_TLS *_tls)
ScripterExport void save_error_source_data (MAXScript_TLS *tls=nullptr)
ScripterExport void clear_error_source_data (MAXScript_TLS *tls=nullptr)

Macro Definition Documentation

◆ one_value_local

#define one_value_local ( n1)
Value:
struct { int count; Value** link; Value* n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
#define NULL
Definition autoptr.h:18
Definition value.h:107
48#define one_value_local(n1) \
49 struct { int count; Value** link; Value* n1; } vl = \
50 { 1, NULL, NULL }; \
51 vl.link = thread_local(current_locals_frame); \
52 thread_local(current_locals_frame) = (Value**)&vl; \
53 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ one_value_local_noFrameValidate

#define one_value_local_noFrameValidate ( n1)
Value:
struct { int count; Value** link; Value* n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false);
55#define one_value_local_noFrameValidate(n1) \
56 struct { int count; Value** link; Value* n1; } vl = \
57 { 1, NULL, NULL }; \
58 vl.link = thread_local(current_locals_frame); \
59 thread_local(current_locals_frame) = (Value**)&vl; \
60 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false);

◆ one_typed_value_local

#define one_typed_value_local ( n1)
Value:
struct { int count; Value** link; n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
62#define one_typed_value_local(n1) \
63 struct { int count; Value** link; n1; } vl = \
64 { 1, NULL, NULL }; \
65 vl.link = thread_local(current_locals_frame); \
66 thread_local(current_locals_frame) = (Value**)&vl; \
67 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ one_typed_value_local_noFrameValidate

#define one_typed_value_local_noFrameValidate ( n1)
Value:
struct { int count; Value** link; n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false);
69#define one_typed_value_local_noFrameValidate(n1) \
70 struct { int count; Value** link; n1; } vl = \
71 { 1, NULL, NULL }; \
72 vl.link = thread_local(current_locals_frame); \
73 thread_local(current_locals_frame) = (Value**)&vl; \
74 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false);

◆ two_value_locals

#define two_value_locals ( n1,
n2 )
Value:
struct { int count; Value** link; Value *n1, *n2; } vl = \
{ 2, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
76#define two_value_locals(n1, n2) \
77 struct { int count; Value** link; Value *n1, *n2; } vl = \
78 { 2, NULL, NULL, NULL }; \
79 vl.link = thread_local(current_locals_frame); \
80 thread_local(current_locals_frame) = (Value**)&vl; \
81 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ two_typed_value_locals

#define two_typed_value_locals ( n1,
n2 )
Value:
struct { int count; Value** link; n1; n2; } vl = \
{ 2, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
83#define two_typed_value_locals(n1, n2) \
84 struct { int count; Value** link; n1; n2; } vl = \
85 { 2, NULL, NULL, NULL }; \
86 vl.link = thread_local(current_locals_frame); \
87 thread_local(current_locals_frame) = (Value**)&vl; \
88 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ three_value_locals

#define three_value_locals ( n1,
n2,
n3 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3; } vl = \
{ 3, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
90#define three_value_locals(n1, n2, n3) \
91 struct { int count; Value** link; Value *n1, *n2, *n3; } vl = \
92 { 3, NULL, NULL, NULL, NULL }; \
93 vl.link = thread_local(current_locals_frame); \
94 thread_local(current_locals_frame) = (Value**)&vl; \
95 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ three_typed_value_locals

#define three_typed_value_locals ( n1,
n2,
n3 )
Value:
struct { int count; Value** link; n1; n2; n3; } vl = \
{ 3, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
97#define three_typed_value_locals(n1, n2, n3) \
98 struct { int count; Value** link; n1; n2; n3; } vl = \
99 { 3, NULL, NULL, NULL, NULL }; \
100 vl.link = thread_local(current_locals_frame); \
101 thread_local(current_locals_frame) = (Value**)&vl; \
102 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ four_value_locals

#define four_value_locals ( n1,
n2,
n3,
n4 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4; } vl = \
{ 4, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
104#define four_value_locals(n1, n2, n3, n4) \
105 struct { int count; Value** link; Value *n1, *n2, *n3, *n4; } vl = \
106 { 4, NULL, NULL, NULL, NULL, NULL }; \
107 vl.link = thread_local(current_locals_frame); \
108 thread_local(current_locals_frame) = (Value**)&vl; \
109 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ four_typed_value_locals

#define four_typed_value_locals ( n1,
n2,
n3,
n4 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; } vl = \
{ 4, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
111#define four_typed_value_locals(n1, n2, n3, n4) \
112 struct { int count; Value** link; n1; n2; n3; n4; } vl = \
113 { 4, NULL, NULL, NULL, NULL, NULL }; \
114 vl.link = thread_local(current_locals_frame); \
115 thread_local(current_locals_frame) = (Value**)&vl; \
116 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ five_value_locals

#define five_value_locals ( n1,
n2,
n3,
n4,
n5 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5; } vl = \
{ 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
118#define five_value_locals(n1, n2, n3, n4, n5) \
119 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5; } vl = \
120 { 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
121 vl.link = thread_local(current_locals_frame); \
122 thread_local(current_locals_frame) = (Value**)&vl; \
123 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ five_typed_value_locals

#define five_typed_value_locals ( n1,
n2,
n3,
n4,
n5 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; } vl = \
{ 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
125#define five_typed_value_locals(n1, n2, n3, n4, n5) \
126 struct { int count; Value** link; n1; n2; n3; n4; n5; } vl = \
127 { 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
128 vl.link = thread_local(current_locals_frame); \
129 thread_local(current_locals_frame) = (Value**)&vl; \
130 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ six_value_locals

#define six_value_locals ( n1,
n2,
n3,
n4,
n5,
n6 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6; } vl = \
{ 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
132#define six_value_locals(n1, n2, n3, n4, n5, n6) \
133 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6; } vl = \
134 { 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
135 vl.link = thread_local(current_locals_frame); \
136 thread_local(current_locals_frame) = (Value**)&vl; \
137 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ six_typed_value_locals

#define six_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; } vl = \
{ 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
139#define six_typed_value_locals(n1, n2, n3, n4, n5, n6) \
140 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; } vl = \
141 { 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
142 vl.link = thread_local(current_locals_frame); \
143 thread_local(current_locals_frame) = (Value**)&vl; \
144 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ seven_value_locals

#define seven_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7; } vl = \
{ 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
146#define seven_value_locals(n1, n2, n3, n4, n5, n6, n7) \
147 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7; } vl = \
148 { 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
149 vl.link = thread_local(current_locals_frame); \
150 thread_local(current_locals_frame) = (Value**)&vl; \
151 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ seven_typed_value_locals

#define seven_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; } vl = \
{ 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
153#define seven_typed_value_locals(n1, n2, n3, n4, n5, n6, n7) \
154 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; } vl = \
155 { 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
156 vl.link = thread_local(current_locals_frame); \
157 thread_local(current_locals_frame) = (Value**)&vl; \
158 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ eight_value_locals

#define eight_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8; } vl = \
{ 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
160#define eight_value_locals(n1, n2, n3, n4, n5, n6, n7, n8) \
161 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8; } vl = \
162 { 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
163 vl.link = thread_local(current_locals_frame); \
164 thread_local(current_locals_frame) = (Value**)&vl; \
165 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ eight_typed_value_locals

#define eight_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; } vl = \
{ 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
167#define eight_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8) \
168 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; } vl = \
169 { 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
170 vl.link = thread_local(current_locals_frame); \
171 thread_local(current_locals_frame) = (Value**)&vl; \
172 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ nine_value_locals

#define nine_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9; } vl = \
{ 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
174#define nine_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9) \
175 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9; } vl = \
176 { 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
177 vl.link = thread_local(current_locals_frame); \
178 thread_local(current_locals_frame) = (Value**)&vl; \
179 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ nine_typed_value_locals

#define nine_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; } vl = \
{ 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
181#define nine_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9) \
182 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; } vl = \
183 { 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
184 vl.link = thread_local(current_locals_frame); \
185 thread_local(current_locals_frame) = (Value**)&vl; \
186 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ ten_value_locals

#define ten_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10; } vl = \
{ 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
188#define ten_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10) \
189 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10; } vl = \
190 { 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
191 vl.link = thread_local(current_locals_frame); \
192 thread_local(current_locals_frame) = (Value**)&vl; \
193 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ ten_typed_value_locals

#define ten_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; } vl = \
{ 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
195#define ten_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10) \
196 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; } vl = \
197 { 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
198 vl.link = thread_local(current_locals_frame); \
199 thread_local(current_locals_frame) = (Value**)&vl; \
200 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ eleven_value_locals

#define eleven_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11; } vl = \
{ 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
202#define eleven_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11) \
203 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11; } vl = \
204 { 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
205 vl.link = thread_local(current_locals_frame); \
206 thread_local(current_locals_frame) = (Value**)&vl; \
207 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ eleven_typed_value_locals

#define eleven_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; } vl = \
{ 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
209#define eleven_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11) \
210 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; } vl = \
211 { 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
212 vl.link = thread_local(current_locals_frame); \
213 thread_local(current_locals_frame) = (Value**)&vl; \
214 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ twelve_value_locals

#define twelve_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12; } vl = \
{ 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
216#define twelve_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12) \
217 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12; } vl = \
218 { 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
219 vl.link = thread_local(current_locals_frame); \
220 thread_local(current_locals_frame) = (Value**)&vl; \
221 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ twelve_typed_value_locals

#define twelve_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; } vl = \
{ 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
223#define twelve_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12) \
224 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; } vl = \
225 { 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
226 vl.link = thread_local(current_locals_frame); \
227 thread_local(current_locals_frame) = (Value**)&vl; \
228 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ thirteen_value_locals

#define thirteen_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13; } vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
230#define thirteen_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13) \
231 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13; } vl = \
232 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
233 vl.link = thread_local(current_locals_frame); \
234 thread_local(current_locals_frame) = (Value**)&vl; \
235 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ thirteen_typed_value_locals

#define thirteen_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; } vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
237#define thirteen_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13) \
238 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; } vl = \
239 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
240 vl.link = thread_local(current_locals_frame); \
241 thread_local(current_locals_frame) = (Value**)&vl; \
242 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ fourteen_value_locals

#define fourteen_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13,
n14 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13, *n14; } vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
244#define fourteen_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14) \
245 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13, *n14; } vl = \
246 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
247 vl.link = thread_local(current_locals_frame); \
248 thread_local(current_locals_frame) = (Value**)&vl; \
249 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ fourteen_typed_value_locals

#define fourteen_typed_value_locals ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13,
n14 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; n14; } vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
thread_local(current_locals_frame) = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
251#define fourteen_typed_value_locals(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14) \
252 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; n14; } vl = \
253 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
254 vl.link = thread_local(current_locals_frame); \
255 thread_local(current_locals_frame) = (Value**)&vl; \
256 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ value_local_array

#define value_local_array ( var,
count )
Value:
MAXScript_TLS* _## var ##_tls = (MAXScript_TLS*)TlsGetValue(thread_locals_index); \
void* _## var ##_alloc_ptr = _malloca(((count) + 2) * sizeof(Value*)); \
var = &((Value**)_## var ##_alloc_ptr)[2]; \
memset(var, 0, (count) * sizeof(Value*)); \
var[-2] = (Value*)(static_cast<INT_PTR>(count)); \
var[-1] = (Value*)_## var ##_tls->current_locals_frame; \
_## var ##_tls->current_locals_frame = &var[-2]; \
MXS_Exit_ValueLocalArray_Scope _## var ##_Exit_ValueLocal_Scope(_## var ##_alloc_ptr, _## var ##_tls);
ScripterExport int thread_locals_index
Class that uses the RAII idiom to push/pop the thread local current_locals_frame.
Definition value_locals.h:36
Definition MAXScript_TLS.h:34
264#define value_local_array(var, count) \
265 MAXScript_TLS* _## var ##_tls = (MAXScript_TLS*)TlsGetValue(thread_locals_index); \
266 void* _## var ##_alloc_ptr = _malloca(((count) + 2) * sizeof(Value*)); \
267 var = &((Value**)_## var ##_alloc_ptr)[2]; \
268 memset(var, 0, (count) * sizeof(Value*)); \
269 var[-2] = (Value*)(static_cast<INT_PTR>(count)); \
270 var[-1] = (Value*)_## var ##_tls->current_locals_frame; \
271 _## var ##_tls->current_locals_frame = &var[-2]; \
272 MXS_Exit_ValueLocalArray_Scope _## var ##_Exit_ValueLocal_Scope(_## var ##_alloc_ptr, _## var ##_tls);

◆ one_value_local_tls

#define one_value_local_tls ( n1)
Value:
struct { int count; Value** link; Value* n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
277#define one_value_local_tls(n1) \
278 struct { int count; Value** link; Value* n1; } vl = \
279 { 1, NULL, NULL }; \
280 vl.link = _tls->current_locals_frame; \
281 _tls->current_locals_frame = (Value**)&vl; \
282 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ one_value_local_noFrameValidate_tls

#define one_value_local_noFrameValidate_tls ( n1)
Value:
struct { int count; Value** link; Value* n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false, _tls);
284#define one_value_local_noFrameValidate_tls(n1) \
285 struct { int count; Value** link; Value* n1; } vl = \
286 { 1, NULL, NULL }; \
287 vl.link = _tls->current_locals_frame; \
288 _tls->current_locals_frame = (Value**)&vl; \
289 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false, _tls);

◆ one_typed_value_local_tls

#define one_typed_value_local_tls ( n1)
Value:
struct { int count; Value** link; n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
291#define one_typed_value_local_tls(n1) \
292 struct { int count; Value** link; n1; } vl = \
293 { 1, NULL, NULL }; \
294 vl.link = _tls->current_locals_frame; \
295 _tls->current_locals_frame = (Value**)&vl; \
296 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ one_typed_value_local_noFrameValidate_tls

#define one_typed_value_local_noFrameValidate_tls ( n1)
Value:
struct { int count; Value** link; n1; } vl = \
{ 1, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false, _tls);
298#define one_typed_value_local_noFrameValidate_tls(n1) \
299 struct { int count; Value** link; n1; } vl = \
300 { 1, NULL, NULL }; \
301 vl.link = _tls->current_locals_frame; \
302 _tls->current_locals_frame = (Value**)&vl; \
303 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(false, _tls);

◆ two_value_locals_tls

#define two_value_locals_tls ( n1,
n2 )
Value:
struct { int count; Value** link; Value *n1, *n2; } vl = \
{ 2, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
305#define two_value_locals_tls(n1, n2) \
306 struct { int count; Value** link; Value *n1, *n2; } vl = \
307 { 2, NULL, NULL, NULL }; \
308 vl.link = _tls->current_locals_frame; \
309 _tls->current_locals_frame = (Value**)&vl; \
310 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ two_typed_value_locals_tls

#define two_typed_value_locals_tls ( n1,
n2 )
Value:
struct { int count; Value** link; n1; n2; } vl = \
{ 2, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
312#define two_typed_value_locals_tls(n1, n2) \
313 struct { int count; Value** link; n1; n2; } vl = \
314 { 2, NULL, NULL, NULL }; \
315 vl.link = _tls->current_locals_frame; \
316 _tls->current_locals_frame = (Value**)&vl; \
317 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ three_value_locals_tls

#define three_value_locals_tls ( n1,
n2,
n3 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3; } vl = \
{ 3, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
319#define three_value_locals_tls(n1, n2, n3) \
320 struct { int count; Value** link; Value *n1, *n2, *n3; } vl = \
321 { 3, NULL, NULL, NULL, NULL }; \
322 vl.link = _tls->current_locals_frame; \
323 _tls->current_locals_frame = (Value**)&vl; \
324 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ three_typed_value_locals_tls

#define three_typed_value_locals_tls ( n1,
n2,
n3 )
Value:
struct { int count; Value** link; n1; n2; n3; } vl = \
{ 3, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
326#define three_typed_value_locals_tls(n1, n2, n3) \
327 struct { int count; Value** link; n1; n2; n3; } vl = \
328 { 3, NULL, NULL, NULL, NULL }; \
329 vl.link = _tls->current_locals_frame; \
330 _tls->current_locals_frame = (Value**)&vl; \
331 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ four_value_locals_tls

#define four_value_locals_tls ( n1,
n2,
n3,
n4 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4; } vl = \
{ 4, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
333#define four_value_locals_tls(n1, n2, n3, n4) \
334 struct { int count; Value** link; Value *n1, *n2, *n3, *n4; } vl = \
335 { 4, NULL, NULL, NULL, NULL, NULL }; \
336 vl.link = _tls->current_locals_frame; \
337 _tls->current_locals_frame = (Value**)&vl; \
338 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ four_typed_value_locals_tls

#define four_typed_value_locals_tls ( n1,
n2,
n3,
n4 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; } vl = \
{ 4, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
340#define four_typed_value_locals_tls(n1, n2, n3, n4) \
341 struct { int count; Value** link; n1; n2; n3; n4; } vl = \
342 { 4, NULL, NULL, NULL, NULL, NULL }; \
343 vl.link = _tls->current_locals_frame; \
344 _tls->current_locals_frame = (Value**)&vl; \
345 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ five_value_locals_tls

#define five_value_locals_tls ( n1,
n2,
n3,
n4,
n5 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5; } vl = \
{ 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
347#define five_value_locals_tls(n1, n2, n3, n4, n5) \
348 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5; } vl = \
349 { 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
350 vl.link = _tls->current_locals_frame; \
351 _tls->current_locals_frame = (Value**)&vl; \
352 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ five_typed_value_locals_tls

#define five_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; } vl = \
{ 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
354#define five_typed_value_locals_tls(n1, n2, n3, n4, n5) \
355 struct { int count; Value** link; n1; n2; n3; n4; n5; } vl = \
356 { 5, NULL, NULL, NULL, NULL, NULL, NULL }; \
357 vl.link = _tls->current_locals_frame; \
358 _tls->current_locals_frame = (Value**)&vl; \
359 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ six_value_locals_tls

#define six_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6; } vl = \
{ 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
361#define six_value_locals_tls(n1, n2, n3, n4, n5, n6) \
362 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6; } vl = \
363 { 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
364 vl.link = _tls->current_locals_frame; \
365 _tls->current_locals_frame = (Value**)&vl; \
366 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ six_typed_value_locals_tls

#define six_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; } vl = \
{ 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
368#define six_typed_value_locals_tls(n1, n2, n3, n4, n5, n6) \
369 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; } vl = \
370 { 6, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
371 vl.link = _tls->current_locals_frame; \
372 _tls->current_locals_frame = (Value**)&vl; \
373 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ seven_value_locals_tls

#define seven_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7; } vl = \
{ 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
375#define seven_value_locals_tls(n1, n2, n3, n4, n5, n6, n7) \
376 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7; } vl = \
377 { 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
378 vl.link = _tls->current_locals_frame; \
379 _tls->current_locals_frame = (Value**)&vl; \
380 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ seven_typed_value_locals_tls

#define seven_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; } vl = \
{ 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
382#define seven_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7) \
383 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; } vl = \
384 { 7, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
385 vl.link = _tls->current_locals_frame; \
386 _tls->current_locals_frame = (Value**)&vl; \
387 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ eight_value_locals_tls

#define eight_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8; } vl = \
{ 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
389#define eight_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8) \
390 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8; } vl = \
391 { 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
392 vl.link = _tls->current_locals_frame; \
393 _tls->current_locals_frame = (Value**)&vl; \
394 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ eight_typed_value_locals_tls

#define eight_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; } vl = \
{ 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
396#define eight_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8) \
397 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; } vl = \
398 { 8, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
399 vl.link = _tls->current_locals_frame; \
400 _tls->current_locals_frame = (Value**)&vl; \
401 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ nine_value_locals_tls

#define nine_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9; } vl = \
{ 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
403#define nine_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9) \
404 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9; } vl = \
405 { 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
406 vl.link = _tls->current_locals_frame; \
407 _tls->current_locals_frame = (Value**)&vl; \
408 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ nine_typed_value_locals_tls

#define nine_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; } vl = \
{ 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
410#define nine_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9) \
411 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; } vl = \
412 { 9, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
413 vl.link = _tls->current_locals_frame; \
414 _tls->current_locals_frame = (Value**)&vl; \
415 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ ten_value_locals_tls

#define ten_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10; } vl = \
{ 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
417#define ten_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10) \
418 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10; } vl = \
419 { 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
420 vl.link = _tls->current_locals_frame; \
421 _tls->current_locals_frame = (Value**)&vl; \
422 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ ten_typed_value_locals_tls

#define ten_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; } vl = \
{ 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
424#define ten_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10) \
425 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; } vl = \
426 { 10, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
427 vl.link = _tls->current_locals_frame; \
428 _tls->current_locals_frame = (Value**)&vl; \
429 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ eleven_value_locals_tls

#define eleven_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11; } vl = \
{ 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
431#define eleven_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11) \
432 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11; } vl = \
433 { 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
434 vl.link = _tls->current_locals_frame; \
435 _tls->current_locals_frame = (Value**)&vl; \
436 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ eleven_typed_value_locals_tls

#define eleven_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; } vl = \
{ 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = _tls->current_locals_frame; \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);
438#define eleven_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11) \
439 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; } vl = \
440 { 11, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
441 vl.link = _tls->current_locals_frame; \
442 _tls->current_locals_frame = (Value**)&vl; \
443 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope(_tls);

◆ twelve_value_locals_tls

#define twelve_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12; } vl = \
{ 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
445#define twelve_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12) \
446 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12; } vl = \
447 { 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
448 vl.link = thread_local(current_locals_frame); \
449 _tls->current_locals_frame = (Value**)&vl; \
450 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ twelve_typed_value_locals_tls

#define twelve_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; } vl = \
{ 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
452#define twelve_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12) \
453 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; } vl = \
454 { 12, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
455 vl.link = thread_local(current_locals_frame); \
456 _tls->current_locals_frame = (Value**)&vl; \
457 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ thirteen_value_locals_tls

#define thirteen_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13; } vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
459#define thirteen_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13) \
460 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13; } vl = \
461 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
462 vl.link = thread_local(current_locals_frame); \
463 _tls->current_locals_frame = (Value**)&vl; \
464 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ thirteen_typed_value_locals_tls

#define thirteen_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; } vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
466#define thirteen_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13) \
467 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; } vl = \
468 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
469 vl.link = thread_local(current_locals_frame); \
470 _tls->current_locals_frame = (Value**)&vl; \
471 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ fourteen_value_locals_tls

#define fourteen_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13,
n14 )
Value:
struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13, *n14;} vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
473#define fourteen_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14) \
474 struct { int count; Value** link; Value *n1, *n2, *n3, *n4, *n5, *n6, *n7, *n8, *n9, *n10, *n11, *n12, *n13, *n14;} vl = \
475 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
476 vl.link = thread_local(current_locals_frame); \
477 _tls->current_locals_frame = (Value**)&vl; \
478 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ fourteen_typed_value_locals_tls

#define fourteen_typed_value_locals_tls ( n1,
n2,
n3,
n4,
n5,
n6,
n7,
n8,
n9,
n10,
n11,
n12,
n13,
n14 )
Value:
struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; n14;} vl = \
{ 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
vl.link = thread_local(current_locals_frame); \
_tls->current_locals_frame = (Value**)&vl; \
MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;
480#define fourteen_typed_value_locals_tls(n1, n2, n3, n4, n5, n6, n7, n8, n9, n10, n11, n12, n13, n14) \
481 struct { int count; Value** link; n1; n2; n3; n4; n5; n6; n7; n8; n9; n10; n11; n12; n13; n14;} vl = \
482 { 13, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }; \
483 vl.link = thread_local(current_locals_frame); \
484 _tls->current_locals_frame = (Value**)&vl; \
485 MXS_Exit_ValueLocal_Scope mxs_Exit_ValueLocal_Scope;

◆ value_local_array_tls

#define value_local_array_tls ( var,
count )
Value:
void* _## var ##_alloc_ptr = _malloca(((count) + 2) * sizeof(Value*)); \
var = &((Value**)_## var ##_alloc_ptr)[2]; \
memset(var, 0, (count) * sizeof(Value*)); \
var[-2] = (Value*)(static_cast<INT_PTR>(count)); \
var[-1] = (Value*)_tls->current_locals_frame; \
_tls->current_locals_frame = &var[-2]; \
MXS_Exit_ValueLocalArray_Scope _## var ##_Exit_ValueLocal_Scope(_## var ##_alloc_ptr, _tls);
487#define value_local_array_tls(var, count) \
488 void* _## var ##_alloc_ptr = _malloca(((count) + 2) * sizeof(Value*)); \
489 var = &((Value**)_## var ##_alloc_ptr)[2]; \
490 memset(var, 0, (count) * sizeof(Value*)); \
491 var[-2] = (Value*)(static_cast<INT_PTR>(count)); \
492 var[-1] = (Value*)_tls->current_locals_frame; \
493 _tls->current_locals_frame = &var[-2]; \
494 MXS_Exit_ValueLocalArray_Scope _## var ##_Exit_ValueLocal_Scope(_## var ##_alloc_ptr, _tls);

◆ return_value

#define return_value ( r)
Value:
Type templated_return_value_fn(Type r)
Definition value_locals.h:500

◆ return_value_tls

#define return_value_tls ( r)
Value:
Type templated_return_value_fn_tls(Type r, MAXScript_TLS *_tls)
Definition value_locals.h:514

◆ save_current_source

#define save_current_source ( )
Value:
Value* _save_source = thread_local(source_file); \
MSZipPackage* _save_pkg = thread_local(current_pkg); \
unsigned int _save_pos = thread_local(source_pos); \
unsigned int _save_line = thread_local(source_line); \
DWORD _save_flags = thread_local(source_flags);
Definition mxsZipPackage.h:40
625#define save_current_source() \
626 Value* _save_source = thread_local(source_file); \
627 MSZipPackage* _save_pkg = thread_local(current_pkg); \
628 unsigned int _save_pos = thread_local(source_pos); \
629 unsigned int _save_line = thread_local(source_line); \
630 DWORD _save_flags = thread_local(source_flags);

◆ restore_current_source

#define restore_current_source ( )
Value:
{ \
thread_local(source_file) = _save_source; \
thread_local(current_pkg) = _save_pkg; \
thread_local(source_pos) = _save_pos; \
thread_local(source_line) = _save_line; \
thread_local(source_flags) = _save_flags;}
632#define restore_current_source() { \
633 thread_local(source_file) = _save_source; \
634 thread_local(current_pkg) = _save_pkg; \
635 thread_local(source_pos) = _save_pos; \
636 thread_local(source_line) = _save_line; \
637 thread_local(source_flags) = _save_flags;}

◆ save_current_source_no_pos

#define save_current_source_no_pos ( )
Value:
Value* _save_source = thread_local(source_file); \
MSZipPackage* _save_pkg = thread_local(current_pkg); \
DWORD _save_flags = thread_local(source_flags);
639#define save_current_source_no_pos() \
640 Value* _save_source = thread_local(source_file); \
641 MSZipPackage* _save_pkg = thread_local(current_pkg); \
642 DWORD _save_flags = thread_local(source_flags);

◆ restore_current_source_no_pos

#define restore_current_source_no_pos ( )
Value:
{ \
thread_local(source_file) = _save_source; \
thread_local(current_pkg) = _save_pkg; \
thread_local(source_flags) = _save_flags;}
644#define restore_current_source_no_pos() { \
645 thread_local(source_file) = _save_source; \
646 thread_local(current_pkg) = _save_pkg; \
647 thread_local(source_flags) = _save_flags;}

◆ save_current_source_pos

#define save_current_source_pos ( )
Value:
unsigned int _save_pos = thread_local(source_pos); \
unsigned int _save_line = thread_local(source_line); \
DWORD _save_flags = thread_local(source_flags);
649#define save_current_source_pos() \
650 unsigned int _save_pos = thread_local(source_pos); \
651 unsigned int _save_line = thread_local(source_line); \
652 DWORD _save_flags = thread_local(source_flags);

◆ restore_current_source_pos

#define restore_current_source_pos ( )
Value:
{ \
thread_local(source_pos) = _save_pos; \
thread_local(source_line) = _save_line; \
thread_local(source_flags) = _save_flags;}
654#define restore_current_source_pos() { \
655 thread_local(source_pos) = _save_pos; \
656 thread_local(source_line) = _save_line; \
657 thread_local(source_flags) = _save_flags;}

◆ save_current_source_to_frame

#define save_current_source_to_frame ( )
Value:
{ \
Value** _frame = thread_local(current_scan_frame); \
if (_frame) _frame[3] = thread_local(source_file); \
if (_frame) _frame[4] = (Value*)thread_local(source_pos); \
if (_frame) _frame[8] = (Value*)thread_local(source_line); \
if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(thread_local(source_flags));}
659#define save_current_source_to_frame() { \
660 Value** _frame = thread_local(current_scan_frame); \
661 if (_frame) _frame[3] = thread_local(source_file); \
662 if (_frame) _frame[4] = (Value*)thread_local(source_pos); \
663 if (_frame) _frame[8] = (Value*)thread_local(source_line); \
664 if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(thread_local(source_flags));}

◆ save_current_source_to_frame_no_pos

#define save_current_source_to_frame_no_pos ( )
Value:
{ \
Value** _frame = thread_local(current_scan_frame); \
if (_frame) _frame[3] = thread_local(source_file); \
if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(thread_local(source_flags));}
666#define save_current_source_to_frame_no_pos() { \
667 Value** _frame = thread_local(current_scan_frame); \
668 if (_frame) _frame[3] = thread_local(source_file); \
669 if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(thread_local(source_flags));}

◆ save_current_source_to_frame_pos

#define save_current_source_to_frame_pos ( )
Value:
{ \
Value** _frame = thread_local(current_scan_frame); \
if (_frame) _frame[4] = (Value*)thread_local(source_pos); \
if (_frame) _frame[8] = (Value*)thread_local(source_line);}
671#define save_current_source_to_frame_pos() { \
672 Value** _frame = thread_local(current_scan_frame); \
673 if (_frame) _frame[4] = (Value*)thread_local(source_pos); \
674 if (_frame) _frame[8] = (Value*)thread_local(source_line);}

◆ save_current_source_to_frame_no_file

#define save_current_source_to_frame_no_file ( )
Value:
{ \
Value** _frame = thread_local(current_scan_frame); \
if (_frame) _frame[4] = (Value*)thread_local(source_pos); \
if (_frame) _frame[8] = (Value*)thread_local(source_line);}
676#define save_current_source_to_frame_no_file() { \
677 Value** _frame = thread_local(current_scan_frame); \
678 if (_frame) _frame[4] = (Value*)thread_local(source_pos); \
679 if (_frame) _frame[8] = (Value*)thread_local(source_line);}

◆ save_current_source_tls

#define save_current_source_tls ( )
Value:
Value* _save_source = _tls->source_file; \
MSZipPackage* _save_pkg = _tls->current_pkg; \
unsigned int _save_pos = _tls->source_pos; \
unsigned int _save_line = _tls->source_line; \
DWORD _save_flags = _tls->source_flags;
684#define save_current_source_tls() \
685 Value* _save_source = _tls->source_file; \
686 MSZipPackage* _save_pkg = _tls->current_pkg; \
687 unsigned int _save_pos = _tls->source_pos; \
688 unsigned int _save_line = _tls->source_line; \
689 DWORD _save_flags = _tls->source_flags;

◆ restore_current_source_tls

#define restore_current_source_tls ( )
Value:
{ \
_tls->source_file = _save_source; \
_tls->current_pkg = _save_pkg; \
_tls->source_pos = _save_pos; \
_tls->source_line = _save_line; \
_tls->source_flags = _save_flags;}
691#define restore_current_source_tls() { \
692 _tls->source_file = _save_source; \
693 _tls->current_pkg = _save_pkg; \
694 _tls->source_pos = _save_pos; \
695 _tls->source_line = _save_line; \
696 _tls->source_flags = _save_flags;}

◆ save_current_source_no_pos_tls

#define save_current_source_no_pos_tls ( )
Value:
Value* _save_source = _tls->source_file; \
MSZipPackage* _save_pkg = _tls->current_pkg; \
DWORD _save_flags = _tls->source_flags;
698#define save_current_source_no_pos_tls() \
699 Value* _save_source = _tls->source_file; \
700 MSZipPackage* _save_pkg = _tls->current_pkg; \
701 DWORD _save_flags = _tls->source_flags;

◆ restore_current_source_no_pos_tls

#define restore_current_source_no_pos_tls ( )
Value:
{ \
_tls->source_file = _save_source; \
_tls->current_pkg = _save_pkg; \
_tls->source_flags = _save_flags;}
703#define restore_current_source_no_pos_tls() { \
704 _tls->source_file = _save_source; \
705 _tls->current_pkg = _save_pkg; \
706 _tls->source_flags = _save_flags;}

◆ save_current_source_pos_tls

#define save_current_source_pos_tls ( )
Value:
unsigned int _save_pos = _tls->source_pos; \
unsigned int _save_line = _tls->source_line; \
DWORD _save_flags = _tls->source_flags;
708#define save_current_source_pos_tls() \
709 unsigned int _save_pos = _tls->source_pos; \
710 unsigned int _save_line = _tls->source_line; \
711 DWORD _save_flags = _tls->source_flags;

◆ restore_current_source_pos_tls

#define restore_current_source_pos_tls ( )
Value:
{ \
_tls->source_pos = _save_pos; \
_tls->source_line = _save_line; \
_tls->source_flags = _save_flags;}
713#define restore_current_source_pos_tls() { \
714 _tls->source_pos = _save_pos; \
715 _tls->source_line = _save_line; \
716 _tls->source_flags = _save_flags;}

◆ save_current_source_to_frame_tls

#define save_current_source_to_frame_tls ( )
Value:
{ \
Value** _frame = _tls->current_scan_frame; \
if (_frame) _frame[3] = _tls->source_file; \
if (_frame) _frame[4] = (Value*)_tls->source_pos; \
if (_frame) _frame[8] = (Value*)_tls->source_line; \
if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(_tls->source_flags);}
718#define save_current_source_to_frame_tls() { \
719 Value** _frame = _tls->current_scan_frame; \
720 if (_frame) _frame[3] = _tls->source_file; \
721 if (_frame) _frame[4] = (Value*)_tls->source_pos; \
722 if (_frame) _frame[8] = (Value*)_tls->source_line; \
723 if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(_tls->source_flags);}

◆ save_current_source_to_frame_no_pos_tls

#define save_current_source_to_frame_no_pos_tls ( )
Value:
{ \
Value** _frame = _tls->current_scan_frame; \
if (_frame) _frame[3] = _tls->source_file; \
if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(_tls->source_flags);}
725#define save_current_source_to_frame_no_pos_tls() { \
726 Value** _frame = _tls->current_scan_frame; \
727 if (_frame) _frame[3] = _tls->source_file; \
728 if (_frame) _frame[7] = (Value*)static_cast<DWORD_PTR>(_tls->source_flags);}

◆ save_current_source_to_frame_pos_tls

#define save_current_source_to_frame_pos_tls ( )
Value:
{ \
Value** _frame = _tls->current_scan_frame; \
if (_frame) _frame[4] = (Value*)_tls->source_pos; \
if (_frame) _frame[8] = (Value*)_tls->source_line;}
730#define save_current_source_to_frame_pos_tls() { \
731 Value** _frame = _tls->current_scan_frame; \
732 if (_frame) _frame[4] = (Value*)_tls->source_pos; \
733 if (_frame) _frame[8] = (Value*)_tls->source_line;}

◆ save_current_source_to_frame_no_file_tls

#define save_current_source_to_frame_no_file_tls ( )
Value:
{ \
Value** _frame = _tls->current_scan_frame; \
if (_frame) _frame[4] = (Value*)_tls->source_pos; \
if (_frame) _frame[8] = (Value*)_tls->source_line;}
735#define save_current_source_to_frame_no_file_tls() { \
736 Value** _frame = _tls->current_scan_frame; \
737 if (_frame) _frame[4] = (Value*)_tls->source_pos; \
738 if (_frame) _frame[8] = (Value*)_tls->source_line;}

Function Documentation

◆ templated_return_value_fn()

template<typename Type>
Type templated_return_value_fn ( Type r)
501{
502 thread_local(current_result) = r;
503 return r;
504}

◆ templated_return_value_fn_tls()

template<typename Type>
Type templated_return_value_fn_tls ( Type r,
MAXScript_TLS * _tls )
515{
516 _tls->current_result = r;
517 return r;
518}

◆ save_error_source_data()

ScripterExport void save_error_source_data ( MAXScript_TLS * tls = nullptr)

◆ clear_error_source_data()

ScripterExport void clear_error_source_data ( MAXScript_TLS * tls = nullptr)