Skip to content

Commit ac03fab

Browse files
authored
Merge pull request github#7753 from aibaars/ruby-3.1
Ruby 3.1 features
2 parents ab2d3a7 + 6525035 commit ac03fab

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+17086
-7028
lines changed

.github/workflows/ruby-qltest.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,14 @@ jobs:
5252
codeql dataset import -S ql/lib/upgrades/initial/ruby.dbscheme testdb empty.trap
5353
codeql dataset upgrade testdb --additional-packs ql/lib
5454
diff -q testdb/ruby.dbscheme ql/lib/ruby.dbscheme
55+
- name: Check DB downgrade scripts
56+
run: |
57+
echo >empty.trap
58+
rm -rf testdb; codeql dataset import -S ql/lib/ruby.dbscheme testdb empty.trap
59+
codeql resolve upgrades --format=lines --allow-downgrades --additional-packs downgrades \
60+
--dbscheme=ql/lib/ruby.dbscheme --target-dbscheme=downgrades/initial/ruby.dbscheme |
61+
xargs codeql execute upgrades testdb
62+
diff -q testdb/ruby.dbscheme downgrades/initial/ruby.dbscheme
5563
qltest:
5664
runs-on: ubuntu-latest
5765
strategy:

ruby/Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
class AstNode extends @ruby_ast_node {
2+
string toString() { none() }
3+
}
4+
5+
class Location extends @location {
6+
string toString() { none() }
7+
}
8+
9+
from AstNode ruby_block_argument, AstNode child, Location location
10+
where
11+
ruby_block_argument_def(ruby_block_argument, location) and
12+
ruby_block_argument_child(ruby_block_argument, child)
13+
select ruby_block_argument, child, location
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
class AstNode extends @ruby_ast_node {
2+
string toString() { none() }
3+
}
4+
5+
class Location extends @location {
6+
string toString() { none() }
7+
}
8+
9+
from AstNode ruby_block_parameter, AstNode name, Location location
10+
where
11+
ruby_block_parameter_def(ruby_block_parameter, location) and
12+
ruby_block_parameter_name(ruby_block_parameter, name)
13+
select ruby_block_parameter, name, location

0 commit comments

Comments
 (0)