[decompiler] handle nested conditionals and gotos better (#693)

* diff check

* try that again

* more small fixes
This commit is contained in:
water111
2021-07-11 21:59:27 -04:00
committed by GitHub
parent 0a9cc68a27
commit f6d5952498
31 changed files with 1896 additions and 2041 deletions
+7 -7
View File
@@ -1410,15 +1410,15 @@ TEST_F(FormRegressionTest, ExprMethod21DeadPoolHeap) {
" )\n"
" )\n"
" )\n"
" (else\n"
" (if (-> arg1 next)\n"
" (&-\n"
" (the-as pointer (-> arg1 next process))\n"
" (the-as uint (&+ (-> arg0 heap base) 4))\n"
" )\n"
" (&- (-> arg0 heap top) (the-as uint (-> arg0 heap base)))\n"
" ((-> arg1 next)\n"
" (&-\n"
" (the-as pointer (-> arg1 next process))\n"
" (the-as uint (&+ (-> arg0 heap base) 4))\n"
" )\n"
" )\n"
" (else\n"
" (&- (-> arg0 heap top) (the-as uint (-> arg0 heap base)))\n"
" )\n"
" )";
test_with_expr(func, type, expected, false, "", {},
"[\t\t[5, \"v1\", \"pointer\"],\n"