Reviewed By: akotulski Differential Revision: D3543519 fbshipit-source-id: 3493bbemaster
parent
5566ca1fd9
commit
0253608fab
@ -0,0 +1,42 @@
|
||||
(*
|
||||
* Copyright (c) 2016 - present Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*)
|
||||
|
||||
let rec do_frontend_checks_stmt cfg cg method_decl stmt =
|
||||
CFrontend_errors.run_frontend_checkers_on_stmt cfg cg method_decl stmt;
|
||||
let _, stmts = Clang_ast_proj.get_stmt_tuple stmt in
|
||||
IList.iter (do_frontend_checks_stmt cfg cg method_decl) stmts
|
||||
|
||||
let rec do_frontend_checks_decl cfg cg decl =
|
||||
let open Clang_ast_t in
|
||||
let info = Clang_ast_proj.get_decl_tuple decl in
|
||||
CLocation.update_curr_file info;
|
||||
(match decl with
|
||||
| FunctionDecl(_, _, _, fdi)
|
||||
| CXXMethodDecl (_, _, _, fdi, _)
|
||||
| CXXConstructorDecl (_, _, _, fdi, _)
|
||||
| CXXConversionDecl (_, _, _, fdi, _)
|
||||
| CXXDestructorDecl (_, _, _, fdi, _) ->
|
||||
(match fdi.Clang_ast_t.fdi_body with
|
||||
| Some stmt -> do_frontend_checks_stmt cfg cg decl stmt
|
||||
| None -> ())
|
||||
| ObjCMethodDecl (_, _, mdi) ->
|
||||
(match mdi.Clang_ast_t.omdi_body with
|
||||
| Some stmt -> do_frontend_checks_stmt cfg cg decl stmt
|
||||
| None -> ())
|
||||
| _ -> ());
|
||||
CFrontend_errors.run_frontend_checkers_on_decl cfg cg decl;
|
||||
match Clang_ast_proj.get_decl_context_tuple decl with
|
||||
| Some (decls, _) -> IList.iter (do_frontend_checks_decl cfg cg) decls
|
||||
| None -> ()
|
||||
|
||||
let do_frontend_checks cfg cg ast =
|
||||
match ast with
|
||||
| Clang_ast_t.TranslationUnitDecl(_, decl_list, _, _) ->
|
||||
IList.iter (do_frontend_checks_decl cfg cg) decl_list
|
||||
| _ -> assert false (* NOTE: Assumes that an AST alsways starts with a TranslationUnitDecl *)
|
@ -0,0 +1,10 @@
|
||||
(*
|
||||
* Copyright (c) 2016 - present Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD style license found in the
|
||||
* LICENSE file in the root directory of this source tree. An additional grant
|
||||
* of patent rights can be found in the PATENTS file in the same directory.
|
||||
*)
|
||||
|
||||
val do_frontend_checks : Cfg.cfg -> Cg.t -> Clang_ast_t.decl -> unit
|
@ -1,145 +1,145 @@
|
||||
/* @generated */
|
||||
digraph iCFG {
|
||||
37 [label="37: DeclStmt \n n$4=_fun___objc_alloc_no_fail(sizeof(class NSAutoreleasePool ):unsigned long ) [line 60]\n n$5=_fun_NSObject_init(n$4:class NSAutoreleasePool *) virtual [line 60]\n *&pool:class NSAutoreleasePool *=n$5 [line 60]\n " shape="box"]
|
||||
37 [label="37: Exit frontend_checks_260aba1187e75a8c3340e4b361681569 \n " color=yellow style=filled]
|
||||
|
||||
|
||||
37 -> 36 ;
|
||||
36 [label="36: DeclStmt \n n$2=_fun___objc_alloc_no_fail(sizeof(class NSString ):unsigned long ) [line 61]\n n$3=_fun___set_autorelease_attribute(n$2:class NSString *) [line 61]\n *&string:class NSString *=n$3 [line 61]\n " shape="box"]
|
||||
36 [label="36: Start frontend_checks_260aba1187e75a8c3340e4b361681569\nFormals: \nLocals: \n " color=yellow style=filled]
|
||||
|
||||
|
||||
36 -> 35 ;
|
||||
35 [label="35: Message Call: release \n n$1=*&pool:class NSAutoreleasePool * [line 63]\n _fun___objc_release_autorelease_pool(n$1:class NSAutoreleasePool *) [line 63]\n " shape="box"]
|
||||
36 -> 37 ;
|
||||
35 [label="35: DeclStmt \n n$4=_fun___objc_alloc_no_fail(sizeof(class NSAutoreleasePool ):unsigned long ) [line 60]\n n$5=_fun_NSObject_init(n$4:class NSAutoreleasePool *) virtual [line 60]\n *&pool:class NSAutoreleasePool *=n$5 [line 60]\n " shape="box"]
|
||||
|
||||
|
||||
35 -> 34 ;
|
||||
34 [label="34: DeclStmt \n n$0=*&string:class NSString * [line 64]\n *&c:class NSString *=n$0 [line 64]\n " shape="box"]
|
||||
34 [label="34: DeclStmt \n n$2=_fun___objc_alloc_no_fail(sizeof(class NSString ):unsigned long ) [line 61]\n n$3=_fun___set_autorelease_attribute(n$2:class NSString *) [line 61]\n *&string:class NSString *=n$3 [line 61]\n " shape="box"]
|
||||
|
||||
|
||||
34 -> 33 ;
|
||||
33 [label="33: Exit test3 \n " color=yellow style=filled]
|
||||
33 [label="33: Message Call: release \n n$1=*&pool:class NSAutoreleasePool * [line 63]\n _fun___objc_release_autorelease_pool(n$1:class NSAutoreleasePool *) [line 63]\n " shape="box"]
|
||||
|
||||
|
||||
32 [label="32: Start test3\nFormals: \nLocals: c:class NSString * string:class NSString * pool:class NSAutoreleasePool * \n DECLARE_LOCALS(&return,&c,&string,&pool); [line 59]\n " color=yellow style=filled]
|
||||
33 -> 32 ;
|
||||
32 [label="32: DeclStmt \n n$0=*&string:class NSString * [line 64]\n *&c:class NSString *=n$0 [line 64]\n " shape="box"]
|
||||
|
||||
|
||||
32 -> 37 ;
|
||||
31 [label="31: DeclStmt \n *&s1:class A *=0 [line 48]\n " shape="box"]
|
||||
32 -> 31 ;
|
||||
31 [label="31: Exit test3 \n " color=yellow style=filled]
|
||||
|
||||
|
||||
31 -> 30 ;
|
||||
30 [label="30: DeclStmt \n *&s2:class A *=0 [line 49]\n " shape="box"]
|
||||
30 [label="30: Start test3\nFormals: \nLocals: c:class NSString * string:class NSString * pool:class NSAutoreleasePool * \n DECLARE_LOCALS(&return,&c,&string,&pool); [line 59]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
30 -> 29 ;
|
||||
29 [label="29: DeclStmt \n *&s3:class A *=0 [line 50]\n " shape="box"]
|
||||
30 -> 35 ;
|
||||
29 [label="29: DeclStmt \n *&s1:class A *=0 [line 48]\n " shape="box"]
|
||||
|
||||
|
||||
29 -> 28 ;
|
||||
28 [label="28: BinaryOperatorStmt: Assign \n n$3=_fun_createA() [line 52]\n *&s1:class A *=n$3 [line 52]\n " shape="box"]
|
||||
28 [label="28: DeclStmt \n *&s2:class A *=0 [line 49]\n " shape="box"]
|
||||
|
||||
|
||||
28 -> 27 ;
|
||||
27 [label="27: BinaryOperatorStmt: Assign \n n$2=_fun_createA() [line 53]\n *&s2:class A *=n$2 [line 53]\n " shape="box"]
|
||||
27 [label="27: DeclStmt \n *&s3:class A *=0 [line 50]\n " shape="box"]
|
||||
|
||||
|
||||
27 -> 26 ;
|
||||
26 [label="26: BinaryOperatorStmt: Assign \n n$1=_fun_createA() [line 54]\n *&s3:class A *=n$1 [line 54]\n " shape="box"]
|
||||
26 [label="26: BinaryOperatorStmt: Assign \n n$3=_fun_createA() [line 52]\n *&s1:class A *=n$3 [line 52]\n " shape="box"]
|
||||
|
||||
|
||||
26 -> 25 ;
|
||||
25 [label="25: Release the autorelease pool \n n$0=_fun___objc_release_autorelease_pool(&s1:class A *,&s3:class A *,&s2:class A *) [line 51]\n " shape="box"]
|
||||
25 [label="25: BinaryOperatorStmt: Assign \n n$2=_fun_createA() [line 53]\n *&s2:class A *=n$2 [line 53]\n " shape="box"]
|
||||
|
||||
|
||||
25 -> 24 ;
|
||||
24 [label="24: Return Stmt \n *&return:int =0 [line 56]\n " shape="box"]
|
||||
24 [label="24: BinaryOperatorStmt: Assign \n n$1=_fun_createA() [line 54]\n *&s3:class A *=n$1 [line 54]\n " shape="box"]
|
||||
|
||||
|
||||
24 -> 23 ;
|
||||
23 [label="23: Exit test2 \n " color=yellow style=filled]
|
||||
23 [label="23: Release the autorelease pool \n n$0=_fun___objc_release_autorelease_pool(&s1:class A *,&s3:class A *,&s2:class A *) [line 51]\n " shape="box"]
|
||||
|
||||
|
||||
22 [label="22: Start test2\nFormals: \nLocals: s3:class A * s2:class A * s1:class A * \n DECLARE_LOCALS(&return,&s3,&s2,&s1); [line 47]\n " color=yellow style=filled]
|
||||
23 -> 22 ;
|
||||
22 [label="22: Return Stmt \n *&return:int =0 [line 56]\n " shape="box"]
|
||||
|
||||
|
||||
22 -> 31 ;
|
||||
21 [label="21: DeclStmt \n *&s1:class A *=0 [line 35]\n " shape="box"]
|
||||
22 -> 21 ;
|
||||
21 [label="21: Exit test2 \n " color=yellow style=filled]
|
||||
|
||||
|
||||
21 -> 20 ;
|
||||
20 [label="20: DeclStmt \n *&s2:class A *=0 [line 36]\n " shape="box"]
|
||||
20 [label="20: Start test2\nFormals: \nLocals: s3:class A * s2:class A * s1:class A * \n DECLARE_LOCALS(&return,&s3,&s2,&s1); [line 47]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
20 -> 19 ;
|
||||
19 [label="19: DeclStmt \n *&s3:class A *=0 [line 37]\n " shape="box"]
|
||||
20 -> 29 ;
|
||||
19 [label="19: DeclStmt \n *&s1:class A *=0 [line 35]\n " shape="box"]
|
||||
|
||||
|
||||
19 -> 18 ;
|
||||
18 [label="18: BinaryOperatorStmt: Assign \n n$5=_fun_createA() [line 39]\n *&s1:class A *=n$5 [line 39]\n " shape="box"]
|
||||
18 [label="18: DeclStmt \n *&s2:class A *=0 [line 36]\n " shape="box"]
|
||||
|
||||
|
||||
18 -> 17 ;
|
||||
17 [label="17: Message Call: retain \n n$3=*&s1:class A * [line 40]\n n$4=_fun___objc_retain(n$3:class A *) [line 40]\n " shape="box"]
|
||||
17 [label="17: DeclStmt \n *&s3:class A *=0 [line 37]\n " shape="box"]
|
||||
|
||||
|
||||
17 -> 16 ;
|
||||
16 [label="16: BinaryOperatorStmt: Assign \n n$2=_fun_createA() [line 41]\n *&s2:class A *=n$2 [line 41]\n " shape="box"]
|
||||
16 [label="16: BinaryOperatorStmt: Assign \n n$5=_fun_createA() [line 39]\n *&s1:class A *=n$5 [line 39]\n " shape="box"]
|
||||
|
||||
|
||||
16 -> 15 ;
|
||||
15 [label="15: BinaryOperatorStmt: Assign \n n$1=_fun_createA() [line 42]\n *&s3:class A *=n$1 [line 42]\n " shape="box"]
|
||||
15 [label="15: Message Call: retain \n n$3=*&s1:class A * [line 40]\n n$4=_fun___objc_retain(n$3:class A *) [line 40]\n " shape="box"]
|
||||
|
||||
|
||||
15 -> 14 ;
|
||||
14 [label="14: Release the autorelease pool \n n$0=_fun___objc_release_autorelease_pool(&s1:class A *,&s2:class A *,&s3:class A *) [line 38]\n " shape="box"]
|
||||
14 [label="14: BinaryOperatorStmt: Assign \n n$2=_fun_createA() [line 41]\n *&s2:class A *=n$2 [line 41]\n " shape="box"]
|
||||
|
||||
|
||||
14 -> 13 ;
|
||||
13 [label="13: Return Stmt \n *&return:int =0 [line 44]\n " shape="box"]
|
||||
13 [label="13: BinaryOperatorStmt: Assign \n n$1=_fun_createA() [line 42]\n *&s3:class A *=n$1 [line 42]\n " shape="box"]
|
||||
|
||||
|
||||
13 -> 12 ;
|
||||
12 [label="12: Exit test1 \n " color=yellow style=filled]
|
||||
12 [label="12: Release the autorelease pool \n n$0=_fun___objc_release_autorelease_pool(&s1:class A *,&s2:class A *,&s3:class A *) [line 38]\n " shape="box"]
|
||||
|
||||
|
||||
11 [label="11: Start test1\nFormals: \nLocals: s3:class A * s2:class A * s1:class A * \n DECLARE_LOCALS(&return,&s3,&s2,&s1); [line 34]\n " color=yellow style=filled]
|
||||
12 -> 11 ;
|
||||
11 [label="11: Return Stmt \n *&return:int =0 [line 44]\n " shape="box"]
|
||||
|
||||
|
||||
11 -> 21 ;
|
||||
10 [label="10: DeclStmt \n n$2=_fun___objc_alloc_no_fail(sizeof(class A ):unsigned long ) [line 30]\n n$3=_fun_NSObject_init(n$2:class A *) virtual [line 30]\n *&s1:class A *=n$3 [line 30]\n " shape="box"]
|
||||
11 -> 10 ;
|
||||
10 [label="10: Exit test1 \n " color=yellow style=filled]
|
||||
|
||||
|
||||
10 -> 9 ;
|
||||
9 [label="9: Return Stmt \n n$0=*&s1:class A * [line 31]\n n$1=_fun___set_autorelease_attribute(n$0:class A *) [line 31]\n *&return:class A *=n$1 [line 31]\n " shape="box"]
|
||||
9 [label="9: Start test1\nFormals: \nLocals: s3:class A * s2:class A * s1:class A * \n DECLARE_LOCALS(&return,&s3,&s2,&s1); [line 34]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
9 -> 8 ;
|
||||
8 [label="8: Exit createA \n " color=yellow style=filled]
|
||||
9 -> 19 ;
|
||||
8 [label="8: DeclStmt \n n$2=_fun___objc_alloc_no_fail(sizeof(class A ):unsigned long ) [line 30]\n n$3=_fun_NSObject_init(n$2:class A *) virtual [line 30]\n *&s1:class A *=n$3 [line 30]\n " shape="box"]
|
||||
|
||||
|
||||
7 [label="7: Start createA\nFormals: \nLocals: s1:class A * \n DECLARE_LOCALS(&return,&s1); [line 29]\n " color=yellow style=filled]
|
||||
8 -> 7 ;
|
||||
7 [label="7: Return Stmt \n n$0=*&s1:class A * [line 31]\n n$1=_fun___set_autorelease_attribute(n$0:class A *) [line 31]\n *&return:class A *=n$1 [line 31]\n " shape="box"]
|
||||
|
||||
|
||||
7 -> 10 ;
|
||||
6 [label="6: DeclStmt \n n$2=_fun___objc_alloc_no_fail(sizeof(class NSString ):unsigned long ) [line 23]\n *&s:class NSString *=n$2 [line 23]\n " shape="box"]
|
||||
7 -> 6 ;
|
||||
6 [label="6: Exit createA \n " color=yellow style=filled]
|
||||
|
||||
|
||||
6 -> 5 ;
|
||||
5 [label="5: Return Stmt \n n$0=*&s:class NSString * [line 24]\n n$1=_fun___set_autorelease_attribute(n$0:class NSString *) [line 24]\n *&return:class NSString *=n$1 [line 24]\n " shape="box"]
|
||||
5 [label="5: Start createA\nFormals: \nLocals: s1:class A * \n DECLARE_LOCALS(&return,&s1); [line 29]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
5 -> 4 ;
|
||||
4 [label="4: Exit A_main \n " color=yellow style=filled]
|
||||
5 -> 8 ;
|
||||
4 [label="4: DeclStmt \n n$2=_fun___objc_alloc_no_fail(sizeof(class NSString ):unsigned long ) [line 23]\n *&s:class NSString *=n$2 [line 23]\n " shape="box"]
|
||||
|
||||
|
||||
3 [label="3: Start A_main\nFormals: self:class A *\nLocals: s:class NSString * \n DECLARE_LOCALS(&return,&s); [line 22]\n " color=yellow style=filled]
|
||||
4 -> 3 ;
|
||||
3 [label="3: Return Stmt \n n$0=*&s:class NSString * [line 24]\n n$1=_fun___set_autorelease_attribute(n$0:class NSString *) [line 24]\n *&return:class NSString *=n$1 [line 24]\n " shape="box"]
|
||||
|
||||
|
||||
3 -> 6 ;
|
||||
2 [label="2: Exit frontend_checks_260aba1187e75a8c3340e4b361681569 \n " color=yellow style=filled]
|
||||
3 -> 2 ;
|
||||
2 [label="2: Exit A_main \n " color=yellow style=filled]
|
||||
|
||||
|
||||
1 [label="1: Start frontend_checks_260aba1187e75a8c3340e4b361681569\nFormals: \nLocals: \n " color=yellow style=filled]
|
||||
1 [label="1: Start A_main\nFormals: self:class A *\nLocals: s:class NSString * \n DECLARE_LOCALS(&return,&s); [line 22]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
1 -> 2 ;
|
||||
1 -> 4 ;
|
||||
}
|
||||
|
@ -1,73 +1,73 @@
|
||||
/* @generated */
|
||||
digraph iCFG {
|
||||
18 [label="18: DeclStmt \n n$3=_fun___objc_alloc_no_fail(sizeof(class A ):unsigned long ) [line 39]\n n$4=_fun_NSObject_init(n$3:class A *) virtual [line 39]\n *&a:class A *=n$4 [line 39]\n " shape="box"]
|
||||
18 [label="18: Exit frontend_checks_23a4fcc8f25cc8087aa9202ac0edfbf5 \n " color=yellow style=filled]
|
||||
|
||||
|
||||
18 -> 17 ;
|
||||
17 [label="17: Message Call: setLast_name: \n n$1=*&a:class A * [line 40]\n n$2=*&a2:class A * [line 40]\n _fun_A_setLast_name:(n$1:class A *,n$2:class A *) [line 40]\n " shape="box"]
|
||||
17 [label="17: Start frontend_checks_23a4fcc8f25cc8087aa9202ac0edfbf5\nFormals: \nLocals: \n " color=yellow style=filled]
|
||||
|
||||
|
||||
17 -> 16 ;
|
||||
16 [label="16: Message Call: release \n n$0=*&a:class A * [line 41]\n _fun___objc_release(n$0:class A *) [line 41]\n " shape="box"]
|
||||
17 -> 18 ;
|
||||
16 [label="16: DeclStmt \n n$3=_fun___objc_alloc_no_fail(sizeof(class A ):unsigned long ) [line 39]\n n$4=_fun_NSObject_init(n$3:class A *) virtual [line 39]\n *&a:class A *=n$4 [line 39]\n " shape="box"]
|
||||
|
||||
|
||||
16 -> 15 ;
|
||||
15 [label="15: Return Stmt \n *&return:int =0 [line 42]\n " shape="box"]
|
||||
15 [label="15: Message Call: setLast_name: \n n$1=*&a:class A * [line 40]\n n$2=*&a2:class A * [line 40]\n _fun_A_setLast_name:(n$1:class A *,n$2:class A *) [line 40]\n " shape="box"]
|
||||
|
||||
|
||||
15 -> 14 ;
|
||||
14 [label="14: Exit test \n " color=yellow style=filled]
|
||||
14 [label="14: Message Call: release \n n$0=*&a:class A * [line 41]\n _fun___objc_release(n$0:class A *) [line 41]\n " shape="box"]
|
||||
|
||||
|
||||
13 [label="13: Start test\nFormals: a2:class A *\nLocals: a:class A * \n DECLARE_LOCALS(&return,&a); [line 38]\n " color=yellow style=filled]
|
||||
14 -> 13 ;
|
||||
13 [label="13: Return Stmt \n *&return:int =0 [line 42]\n " shape="box"]
|
||||
|
||||
|
||||
13 -> 18 ;
|
||||
12 [label="12: DeclStmt \n n$11=_fun___objc_alloc_no_fail(sizeof(class A ):unsigned long ) [line 27]\n n$12=_fun_NSObject_init(n$11:class A *) virtual [line 27]\n *&other:class A *=n$12 [line 27]\n " shape="box"]
|
||||
13 -> 12 ;
|
||||
12 [label="12: Exit test \n " color=yellow style=filled]
|
||||
|
||||
|
||||
12 -> 7 ;
|
||||
12 -> 8 ;
|
||||
11 [label="11: BinaryOperatorStmt: Assign \n n$8=*&other:class A * [line 29]\n n$9=*&self:class A * [line 29]\n n$10=*n$9._name:class A * [line 29]\n *n$8._name:class A *=n$10 [line 29]\n " shape="box"]
|
||||
11 [label="11: Start test\nFormals: a2:class A *\nLocals: a:class A * \n DECLARE_LOCALS(&return,&a); [line 38]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
11 -> 10 ;
|
||||
10 [label="10: BinaryOperatorStmt: Assign \n n$5=*&other:class A * [line 30]\n n$6=*&self:class A * [line 30]\n n$7=*n$6._last_name:class A * [line 30]\n *n$5._last_name:class A *=n$7 [line 30]\n " shape="box"]
|
||||
11 -> 16 ;
|
||||
10 [label="10: DeclStmt \n n$11=_fun___objc_alloc_no_fail(sizeof(class A ):unsigned long ) [line 27]\n n$12=_fun_NSObject_init(n$11:class A *) virtual [line 27]\n *&other:class A *=n$12 [line 27]\n " shape="box"]
|
||||
|
||||
|
||||
10 -> 9 ;
|
||||
9 [label="9: BinaryOperatorStmt: Assign \n n$2=*&other:class A * [line 31]\n n$3=*&self:class A * [line 31]\n n$4=*n$3._child:class A * [line 31]\n *n$2._child:class A *=n$4 [line 31]\n " shape="box"]
|
||||
10 -> 5 ;
|
||||
10 -> 6 ;
|
||||
9 [label="9: BinaryOperatorStmt: Assign \n n$8=*&other:class A * [line 29]\n n$9=*&self:class A * [line 29]\n n$10=*n$9._name:class A * [line 29]\n *n$8._name:class A *=n$10 [line 29]\n " shape="box"]
|
||||
|
||||
|
||||
9 -> 6 ;
|
||||
8 [label="8: Prune (false branch) \n n$1=*&other:class A * [line 28]\n PRUNE((n$1 == 0), false); [line 28]\n " shape="invhouse"]
|
||||
9 -> 8 ;
|
||||
8 [label="8: BinaryOperatorStmt: Assign \n n$5=*&other:class A * [line 30]\n n$6=*&self:class A * [line 30]\n n$7=*n$6._last_name:class A * [line 30]\n *n$5._last_name:class A *=n$7 [line 30]\n " shape="box"]
|
||||
|
||||
|
||||
8 -> 6 ;
|
||||
7 [label="7: Prune (true branch) \n n$1=*&other:class A * [line 28]\n PRUNE((n$1 != 0), true); [line 28]\n " shape="invhouse"]
|
||||
8 -> 7 ;
|
||||
7 [label="7: BinaryOperatorStmt: Assign \n n$2=*&other:class A * [line 31]\n n$3=*&self:class A * [line 31]\n n$4=*n$3._child:class A * [line 31]\n *n$2._child:class A *=n$4 [line 31]\n " shape="box"]
|
||||
|
||||
|
||||
7 -> 11 ;
|
||||
6 [label="6: + \n " ]
|
||||
7 -> 4 ;
|
||||
6 [label="6: Prune (false branch) \n n$1=*&other:class A * [line 28]\n PRUNE((n$1 == 0), false); [line 28]\n " shape="invhouse"]
|
||||
|
||||
|
||||
6 -> 5 ;
|
||||
5 [label="5: Return Stmt \n n$0=*&other:class A * [line 33]\n *&return:class A *=n$0 [line 33]\n " shape="box"]
|
||||
6 -> 4 ;
|
||||
5 [label="5: Prune (true branch) \n n$1=*&other:class A * [line 28]\n PRUNE((n$1 != 0), true); [line 28]\n " shape="invhouse"]
|
||||
|
||||
|
||||
5 -> 4 ;
|
||||
4 [label="4: Exit A_copy \n " color=yellow style=filled]
|
||||
5 -> 9 ;
|
||||
4 [label="4: + \n " ]
|
||||
|
||||
|
||||
3 [label="3: Start A_copy\nFormals: self:class A *\nLocals: other:class A * \n DECLARE_LOCALS(&return,&other); [line 26]\n " color=yellow style=filled]
|
||||
4 -> 3 ;
|
||||
3 [label="3: Return Stmt \n n$0=*&other:class A * [line 33]\n *&return:class A *=n$0 [line 33]\n " shape="box"]
|
||||
|
||||
|
||||
3 -> 12 ;
|
||||
2 [label="2: Exit frontend_checks_23a4fcc8f25cc8087aa9202ac0edfbf5 \n " color=yellow style=filled]
|
||||
3 -> 2 ;
|
||||
2 [label="2: Exit A_copy \n " color=yellow style=filled]
|
||||
|
||||
|
||||
1 [label="1: Start frontend_checks_23a4fcc8f25cc8087aa9202ac0edfbf5\nFormals: \nLocals: \n " color=yellow style=filled]
|
||||
1 [label="1: Start A_copy\nFormals: self:class A *\nLocals: other:class A * \n DECLARE_LOCALS(&return,&other); [line 26]\n " color=yellow style=filled]
|
||||
|
||||
|
||||
1 -> 2 ;
|
||||
1 -> 10 ;
|
||||
}
|
||||
|
Loading…
Reference in new issue