renamed "jumpTargets" to "jump_targets"

This commit is contained in:
Erik Krogh Kristensen
2020-09-04 11:51:45 +02:00
parent 059d72858a
commit 76f728aacd
10 changed files with 17 additions and 10 deletions

View File

@@ -1222,7 +1222,7 @@ public class ASTExtractor {
Label key = super.visit(nd, c); Label key = super.visit(nd, c);
visit(nd.getLabel(), key, 0, IdContext.label); visit(nd.getLabel(), key, 0, IdContext.label);
Label targetKey = trapwriter.localID(contextManager.getTarget(nd)); Label targetKey = trapwriter.localID(contextManager.getTarget(nd));
trapwriter.addTuple("jumpTargets", key, targetKey); trapwriter.addTuple("jump_targets", key, targetKey);
return key; return key;
} }

View File

@@ -1064,7 +1064,7 @@ stmts(#20369,6,#20365,3,"continue;")
locations_default(#20370,#10000,13,5,13,13) locations_default(#20370,#10000,13,5,13,13)
hasLocation(#20369,#20370) hasLocation(#20369,#20370)
stmt_containers(#20369,#20001) stmt_containers(#20369,#20001)
jumpTargets(#20369,#20365) jump_targets(#20369,#20365)
#20371=* #20371=*
stmts(#20371,17,#20001,2,"functio ... (p);\n}") stmts(#20371,17,#20001,2,"functio ... (p);\n}")
#20372=@"loc,{#10000},15,1,18,1" #20372=@"loc,{#10000},15,1,18,1"

View File

@@ -313,7 +313,7 @@ stmts(#20102,5,#20098,0,"break;")
locations_default(#20103,#10000,10,5,10,10) locations_default(#20103,#10000,10,5,10,10)
hasLocation(#20102,#20103) hasLocation(#20102,#20103)
stmt_containers(#20102,#20001) stmt_containers(#20102,#20001)
jumpTargets(#20102,#20093) jump_targets(#20102,#20093)
#20104=* #20104=*
stmts(#20104,19,#20093,2,"default:") stmts(#20104,19,#20093,2,"default:")
hasLocation(#20104,#20023) hasLocation(#20104,#20023)

View File

@@ -718,7 +718,7 @@ hasLocation(#20258,#20097)
enclosingStmt(#20258,#20256) enclosingStmt(#20258,#20256)
exprContainers(#20258,#20001) exprContainers(#20258,#20001)
literals("outer","outer",#20258) literals("outer","outer",#20258)
jumpTargets(#20256,#20237) jump_targets(#20256,#20237)
#20259=* #20259=*
stmts(#20259,3,#20252,2,"if (e)\n ... ntinue;") stmts(#20259,3,#20252,2,"if (e)\n ... ntinue;")
#20260=@"loc,{#10000},7,14,10,21" #20260=@"loc,{#10000},7,14,10,21"
@@ -746,14 +746,14 @@ hasLocation(#20265,#20113)
enclosingStmt(#20265,#20263) enclosingStmt(#20265,#20263)
exprContainers(#20265,#20001) exprContainers(#20265,#20001)
literals("outer","outer",#20265) literals("outer","outer",#20265)
jumpTargets(#20263,#20237) jump_targets(#20263,#20237)
#20266=* #20266=*
stmts(#20266,6,#20259,2,"continue;") stmts(#20266,6,#20259,2,"continue;")
#20267=@"loc,{#10000},10,13,10,21" #20267=@"loc,{#10000},10,13,10,21"
locations_default(#20267,#10000,10,13,10,21) locations_default(#20267,#10000,10,13,10,21)
hasLocation(#20266,#20267) hasLocation(#20266,#20267)
stmt_containers(#20266,#20001) stmt_containers(#20266,#20001)
jumpTargets(#20266,#20250) jump_targets(#20266,#20250)
#20268=* #20268=*
stmts(#20268,13,#20001,2,"do {\n ... ile(a);") stmts(#20268,13,#20001,2,"do {\n ... ile(a);")
#20269=@"loc,{#10000},13,1,15,11" #20269=@"loc,{#10000},13,1,15,11"

View File

@@ -386,7 +386,7 @@ stmts(#20136,5,#20134,0,"break;")
locations_default(#20137,#10000,3,5,3,10) locations_default(#20137,#10000,3,5,3,10)
hasLocation(#20136,#20137) hasLocation(#20136,#20137)
stmt_containers(#20136,#20001) stmt_containers(#20136,#20001)
jumpTargets(#20136,#20130) jump_targets(#20136,#20130)
#20138=* #20138=*
stmts(#20138,19,#20130,1,"case 23 ... += 19;") stmts(#20138,19,#20130,1,"case 23 ... += 19;")
#20139=@"loc,{#10000},4,1,5,12" #20139=@"loc,{#10000},4,1,5,12"

View File

@@ -96,3 +96,8 @@ deprecated predicate isClosureModule(TopLevel toplevel) { is_closure_module(topl
* Use `ASTNode#getContainer()` instead. * Use `ASTNode#getContainer()` instead.
*/ */
deprecated predicate stmtContainers(Stmt stmt, StmtContainer container) { stmt_containers(stmt, container) } deprecated predicate stmtContainers(Stmt stmt, StmtContainer container) { stmt_containers(stmt, container) }
/**
* Alias for the predicate `jump_targets` defined in the .dbscheme.
* Use `JumpStmt#getTarget()` instead.
*/
deprecated predicate jumpTargets(Stmt jump, Stmt target) { jump_targets(jump, target) }

View File

@@ -509,7 +509,7 @@ class BreakOrContinueStmt extends TBreakOrContinueStmt, JumpStmt {
predicate hasTargetLabel() { exists(getTargetLabel()) } predicate hasTargetLabel() { exists(getTargetLabel()) }
/** Gets the statement this statement breaks out of or continues with. */ /** Gets the statement this statement breaks out of or continues with. */
override Stmt getTarget() { jumpTargets(this, result) } override Stmt getTarget() { jump_targets(this, result) }
override predicate isSubjectToSemicolonInsertion() { any() } override predicate isSubjectToSemicolonInsertion() { any() }
} }

View File

@@ -142,7 +142,7 @@ stmts (unique int id: @stmt,
stmt_containers (unique int stmt: @stmt ref, stmt_containers (unique int stmt: @stmt ref,
int container: @stmt_container ref); int container: @stmt_container ref);
jumpTargets (unique int jump: @stmt ref, jump_targets (unique int jump: @stmt ref,
int target: @stmt ref); int target: @stmt ref);
@stmtparent = @stmt | @toplevel | @functionexpr | @arrowfunctionexpr; @stmtparent = @stmt | @toplevel | @functionexpr | @arrowfunctionexpr;

View File

@@ -10133,7 +10133,7 @@
</dependencies> </dependencies>
</relation> </relation>
<relation> <relation>
<name>jumpTargets</name> <name>jump_targets</name>
<cardinality>11791</cardinality> <cardinality>11791</cardinality>
<columnsizes> <columnsizes>
<e> <e>

View File

@@ -12,3 +12,5 @@ is_closure_module.rel: reorder isClosureModule.rel(int toplevel) toplevel
isClosureModule.rel: delete isClosureModule.rel: delete
stmt_containers.rel: reorder stmtContainers.rel(int stmt, int container) stmt container stmt_containers.rel: reorder stmtContainers.rel(int stmt, int container) stmt container
stmtContainers.rel: delete stmtContainers.rel: delete
jump_targets.rel: reorder jumpTargets.rel(int jump, int target) jump target
jumpTargets.rel: delete