@@ -202,16 +202,18 @@ TSEValue = record
202
202
end ;
203
203
204
204
TSEValueHelper = record helper for TSEValue
205
- procedure AllocBuffer (constref Size: Integer); inline; overload;
206
- procedure AllocMap ; inline; overload;
207
- procedure AllocString (const S: String); inline; overload;
208
- procedure AllocPascalObject (const Obj: TObject; const IsManaged: Boolean = True); inline; overload;
205
+ procedure AllocBuffer (constref Size: Integer); inline;
206
+ procedure AllocMap ; inline;
207
+ procedure AllocString (const S: String); inline;
208
+ procedure AllocPascalObject (const Obj: TObject; const IsManaged: Boolean = True); inline;
209
209
function GetValue (constref I: Integer): TSEValue; inline; overload;
210
210
function GetValue (constref S: String): TSEValue; inline; overload;
211
211
function GetValue (constref I: TSEValue): TSEValue; inline; overload;
212
212
procedure SetValue (constref I: Integer; const A: TSEValue); inline; overload;
213
213
procedure SetValue (constref S: String; const A: TSEValue); inline; overload;
214
214
procedure SetValue (I: TSEValue; const A: TSEValue); inline; overload;
215
+ procedure Lock ; inline;
216
+ procedure Unlock ; inline;
215
217
end ;
216
218
217
219
TSEValueList = specialize TList<TSEValue>;
@@ -1129,22 +1131,22 @@ procedure SEMapSet(constref V, I: TSEValue; const A: TSEValue); inline; overload
1129
1131
TSEValueMap(V.VarMap).Set2(S, A);
1130
1132
end ;
1131
1133
1132
- procedure TSEValueHelper.AllocBuffer (constref Size: Integer); inline; overload;
1134
+ procedure TSEValueHelper.AllocBuffer (constref Size: Integer); inline;
1133
1135
begin
1134
1136
GC.AllocBuffer(@Self, Size);
1135
1137
end ;
1136
1138
1137
- procedure TSEValueHelper.AllocMap ; inline; overload;
1139
+ procedure TSEValueHelper.AllocMap ; inline;
1138
1140
begin
1139
1141
GC.AllocMap(@Self);
1140
1142
end ;
1141
1143
1142
- procedure TSEValueHelper.AllocString (const S: String); inline; overload;
1144
+ procedure TSEValueHelper.AllocString (const S: String); inline;
1143
1145
begin
1144
1146
GC.AllocString(@Self, S);
1145
1147
end ;
1146
1148
1147
- procedure TSEValueHelper.AllocPascalObject (const Obj: TObject; const IsManaged: Boolean = True); inline; overload;
1149
+ procedure TSEValueHelper.AllocPascalObject (const Obj: TObject; const IsManaged: Boolean = True); inline;
1148
1150
begin
1149
1151
GC.AllocPascalObject(@Self, Obj, IsManaged);
1150
1152
end ;
@@ -1179,6 +1181,16 @@ procedure TSEValueHelper.SetValue(I: TSEValue; const A: TSEValue); inline; overl
1179
1181
SEMapSet(Self, I, A);
1180
1182
end ;
1181
1183
1184
+ procedure TSEValueHelper.Lock ; inline;
1185
+ begin
1186
+ GC.Lock(@Self);
1187
+ end ;
1188
+
1189
+ procedure TSEValueHelper.Unlock ; inline;
1190
+ begin
1191
+ GC.Unlock(@Self);
1192
+ end ;
1193
+
1182
1194
function SEMapIsValidArray (constref V: TSEValue): Boolean; inline;
1183
1195
begin
1184
1196
if V.Kind <> sevkMap then
0 commit comments