Ruby: rename getConst -> getConstant

This commit is contained in:
Asger F
2022-11-08 16:41:04 +01:00
parent a75c50620c
commit 271de66f01
6 changed files with 22 additions and 20 deletions

View File

@@ -210,7 +210,7 @@ getTopLevelConst
| XY2 | tst.rb:44:9:45:11 | self (XY2) |
| XY3 | tst.rb:53:5:54:7 | self (XY3) |
| Y | tst.rb:53:17:53:17 | Y |
getConst
getConstant
| tst.rb:41:17:41:17 | X | Y | tst.rb:41:17:41:20 | Y |
| tst.rb:44:21:44:21 | X | Y | tst.rb:44:21:44:24 | Y |
| tst.rb:50:13:50:13 | X | X | tst.rb:50:13:50:13 | X |

View File

@@ -50,12 +50,14 @@ query DataFlow::ModuleNode getNestedModule(DataFlow::ModuleNode mod, string name
result = mod.getNestedModule(name)
}
query DataFlow::Node getTopLevelConst(string name) { result = DataFlow::getConst(name) }
query DataFlow::Node getTopLevelConst(string name) { result = DataFlow::getConstant(name) }
query DataFlow::Node getConst(DataFlow::ConstRef base, string name) { result = base.getConst(name) }
query DataFlow::Node getConstant(DataFlow::ConstRef base, string name) {
result = base.getConstant(name)
}
query DataFlow::ModuleNode getXYClasses() {
result = DataFlow::getConst("X").getConst("Y").getADescendentModule()
result = DataFlow::getConstant("X").getConstant("Y").getADescendentModule()
}
query DataFlow::HashLiteralNode hashLiteralNode() { any() }