Adds NodeUtil.deleteNodePreservingValidAST similar to deleteChild but also preserves a valid AST.
Patch also fixes NodeUtil.removeChild to handle comma and binary expressions correctly.
Integration tests optimized size report:
**************************************
-There are 1 size changes.
-Total size (of already existing tests) changed from
- 1488619 to 1488631 bytes (100%->100.00%) and from
- 467916 to 467925 bytes (100%->100.00%) gzipped.
+There are 0 size changes.
+Total size (of already existing tests) did not change.
New reports:
@@ -18,8 +16,7 @@ Shrinkage report highlights:
Expansion report highlights:
**************************************
- old new
- 35172 35181 box2d_noclassmetadata_checksmin (0.03%)
+ none
All reports:
@@ -46,7 +43,7 @@ All reports:
1002 1002 blockscoping (unchanged)
39102 39102 box2d_default (unchanged)
36940 36940 box2d_noclassmetadata (unchanged)
- 35172 35181 box2d_noclassmetadata_checksmin (0.03%)
+ 35181 35181 box2d_noclassmetadata_checksmin (unchanged)
36818 36818 box2d_noclassmetadata_checksopt (unchanged)
3515 3515 boxingsideeffect (unchanged)
1047 1047 breakstatement (unchanged)
