Summary: - Add `no_return` models for Java's `exit(...)` methods (can be extended further later on) - handle throw-catch better by short-cutting throw nodes to not exit node but to all **catch nodes** that are reachable by the node. If there is no catch node, we short-cut to the exit node as before. This removes a FP from deadstore tests because before we simply were not able to handle CF from throw-> catch nodes at all. Reviewed By: skcho Differential Revision: D20769039 fbshipit-source-id: e978f6cdbmaster
parent
cf5925494c
commit
cec8cbeff2
@ -0,0 +1,16 @@
|
||||
(*
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*)
|
||||
|
||||
open! IStd
|
||||
|
||||
let no_return = true
|
||||
|
||||
let dispatch : (Tenv.t, bool, unit) ProcnameDispatcher.ProcName.dispatcher =
|
||||
let open ProcnameDispatcher.ProcName in
|
||||
make_dispatcher
|
||||
[ +PatternMatch.implements_lang "System" &:: "exit" <>--> no_return
|
||||
; +PatternMatch.implements_lang "Runtime" &:: "exit" <>--> no_return ]
|
Loading…
Reference in new issue