@@ -224,6 +224,133 @@ suite("GDB Value Expansion", () => {
224224			} 
225225		] ) ; 
226226	} ) ; 
227+ 	test ( "QT Complex node" ,  ( )  =>  { 
228+ 		const  node  =  `{{ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = -1}, <No data fields>}}}, size = 0, static shared_null = <same type>}, {ref = {atomic = {_q_value = {<std::__atomic_base<int>> = {static _S_alignment = 4, _M_i = 0}, <No data fields>}}}, size = 0, static shared_null = <same type>}}` ; 
229+ 		assert . strictEqual ( isExpandable ( node ) ,  1 ) ; 
230+ 		const  variables  =  expandValue ( variableCreate ,  node ) ; 
231+ 		assert . deepStrictEqual ( variables ,  [ 
232+ 			{ 
233+ 				"name" : "[0]" , 
234+ 				"value" : "Object" , 
235+ 				"variablesReference" : { 
236+ 					"expanded" : [ 
237+ 						{ 
238+ 							"name" : "ref" , 
239+ 							"value" : "Object" , 
240+ 							"variablesReference" : { 
241+ 								"expanded" : [ 
242+ 									{ 
243+ 										"name" : "atomic" , 
244+ 										"value" : "Object" , 
245+ 										"variablesReference" : { 
246+ 											"expanded" : [ 
247+ 												{ 
248+ 													"name" : "_q_value" , 
249+ 													"value" : "Object" , 
250+ 													"variablesReference" : { 
251+ 														"expanded" : [ 
252+ 															{ 
253+ 																"name" : "std::__atomic_base<int>>" , 
254+ 																"value" : "Object" , 
255+ 																"variablesReference" : { 
256+ 																	"expanded" : [ 
257+ 																		{ 
258+ 																			"name" : "_S_alignment" , 
259+ 																			"value" : "4" , 
260+ 																			"variablesReference" : 0 
261+ 																		} , 
262+ 																		{ 
263+ 																			"name" : "_M_i" , 
264+ 																			"value" : "-1" , 
265+ 																			"variablesReference" : 0 
266+ 																		} 
267+ 																	] 
268+ 																} 
269+ 															} 
270+ 														] 
271+ 													} 
272+ 												} 
273+ 											] 
274+ 										} 
275+ 									} 
276+ 								] 
277+ 							} 
278+ 						} , 
279+ 						{ 
280+ 							"name" : "size" , 
281+ 							"value" : "0" , 
282+ 							"variablesReference" : 0 
283+ 						} , 
284+ 						{ 
285+ 							"name" : "shared_null" , 
286+ 							"value" : "<same type>" , 
287+ 							"variablesReference" : 0 
288+ 						} 
289+ 					] 
290+ 				} 
291+ 			} , 
292+ 			{ 
293+ 				"name" : "[1]" , 
294+ 				"value" : "Object" , 
295+ 				"variablesReference" : { 
296+ 					"expanded" : [ 
297+ 						{ 
298+ 							"name" : "ref" , 
299+ 							"value" : "Object" , 
300+ 							"variablesReference" : { 
301+ 								"expanded" : [ 
302+ 									{ 
303+ 										"name" : "atomic" , 
304+ 										"value" : "Object" , 
305+ 										"variablesReference" : { 
306+ 											"expanded" : [ 
307+ 												{ 
308+ 													"name" : "_q_value" , 
309+ 													"value" : "Object" , 
310+ 													"variablesReference" : { 
311+ 														"expanded" : [ 
312+ 															{ 
313+ 																"name" : "std::__atomic_base<int>>" , 
314+ 																"value" : "Object" , 
315+ 																"variablesReference" : { 
316+ 																	"expanded" : [ 
317+ 																		{ 
318+ 																			"name" : "_S_alignment" , 
319+ 																			"value" : "4" , 
320+ 																			"variablesReference" : 0 
321+ 																		} , 
322+ 																		{ 
323+ 																			"name" : "_M_i" , 
324+ 																			"value" : "0" , 
325+ 																			"variablesReference" : 0 
326+ 																		} 
327+ 																	] 
328+ 																} 
329+ 															} 
330+ 														] 
331+ 													} 
332+ 												} 
333+ 											] 
334+ 										} 
335+ 									} 
336+ 								] 
337+ 							} 
338+ 						} , 
339+ 						{ 
340+ 							"name" : "size" , 
341+ 							"value" : "0" , 
342+ 							"variablesReference" : 0 
343+ 						} , 
344+ 						{ 
345+ 							"name" : "shared_null" , 
346+ 							"value" : "<same type>" , 
347+ 							"variablesReference" : 0 
348+ 						} 
349+ 					] 
350+ 				} 
351+ 			} 
352+ 		] ) ; 
353+ 	} ) ; 
227354	test ( "Simple node with errors" ,  ( )  =>  { 
228355		const  node  =  `{_enableMipMaps = false, _minFilter = <incomplete type>, _magFilter = <incomplete type>, _wrapX = <incomplete type>, _wrapY = <incomplete type>, _inMode = 6408, _mode = 6408, _id = 1, _width = 1024, _height = 1024}` ; 
229356		assert . strictEqual ( isExpandable ( node ) ,  1 ) ; 
0 commit comments