node/lib/metasm/metasm/decompile.rb
# changes ifgoto, goto to while/ifelse..
changes ifgoto, goto to while/ifelse
changes ifgoto goto to while / ifelse
def decompile_controlseq(scope)
		scope.statements = decompile_cseq_if(scope.statements, scope)
		remove_labels(scope)
		scope.statements = decompile_cseq_if(scope.statements, scope)
		remove_labels(scope)
		decompile_cseq_while(scope.statements, scope)
		decompile_cseq_switch(scope)
	end
def decompile_controlseq ( scope ) scope . statements = decompile_cseq_if ( scope . statements , scope ) remove_labels ( scope ) scope . statements = decompile_cseq_if ( scope . statements , scope ) remove_labels ( scope ) decompile_cseq_while ( scope . statements , scope ) decompile_cseq_switch ( scope ) end
changes ifgoto, goto to while/ifelse..
changes ifgoto goto to while / ifelse ..
# TODO replace all this crap by a method using the graph representation # TODO harmonize _if/_while api (if returns a replacement, while patches)
scope