Commit Graph

1688 Commits

Author SHA1 Message Date
Geoffrey White
03f94de3cb Rust: Add models. 2025-03-31 17:39:15 +01:00
Geoffrey White
9409cd6ed7 Rust: Prototype query. 2025-03-31 17:39:11 +01:00
Geoffrey White
ae555f2f2e Rust: Add a test for uncontrolled allocation size. 2025-03-31 17:37:21 +01:00
Anders Schack-Mulligen
0c74f21107 Merge pull request #19044 from aschackmull/ssa/useuse-trim
Ssa: Trim the use-use relation to skip irrelevant nodes
2025-03-28 11:55:34 +01:00
Tom Hvitved
f2f5739cc7 Merge pull request #19123 from hvitved/rust/path-resolution-crate-non-source
Rust: Also resolve `crate` paths in non-source files
2025-03-28 11:45:36 +01:00
Arthur Baars
7fc7b7cc04 Rust: fix CleartextLogging query 2025-03-27 18:38:57 +00:00
Arthur Baars
6dff6826f0 Revert "Rust: accept test changes for now"
This reverts commit bf32acc198.
2025-03-27 18:33:00 +00:00
Simon Friis Vindum
533fdcf332 Rust: Remove unnecessary seperator 2025-03-27 12:56:54 +01:00
Simon Friis Vindum
0d75054955 Rust: Implement toString on type aliases and add docs 2025-03-27 11:34:39 +01:00
Arthur Baars
9dd7b20db7 Merge pull request #18960 from github/aibaars/rust-tainted-path
Rust: TaintedPath query
2025-03-27 10:37:36 +01:00
Tamas Vajk
34e8318797 Rename the CCR query suite to code-quality 2025-03-27 08:36:53 +01:00
Arthur Baars
bf76505880 Rust: address comments 2025-03-26 13:28:44 +01:00
Tom Hvitved
284df7fcf3 Rust: Also resolve crate paths in non-source files 2025-03-26 11:29:34 +01:00
Tom Hvitved
f45eca77fa Address review comments 2025-03-26 09:03:22 +01:00
Tom Hvitved
72028c034e Rust: Add reverse post-update flow steps 2025-03-26 09:03:18 +01:00
Tom Hvitved
fcb1d9433a Rust: Add more data flow tests 2025-03-26 09:02:23 +01:00
Tom Hvitved
278d251dc1 Merge pull request #19107 from hvitved/rust/mad-argument-source
Rust: Support `Argument[x]` MaD source definitions
2025-03-26 09:02:06 +01:00
Tom Hvitved
b4926475d3 Address review comment 2025-03-26 08:44:03 +01:00
Geoffrey White
3ad4de400f Merge pull request #19067 from geoffw0/convtest
Rust: Add a couple of test cases for data flow through conversions
2025-03-25 17:44:29 +00:00
Anders Schack-Mulligen
d5d0274ce7 Java/SSA: Keep proper distinction between cached stages. 2025-03-25 13:43:55 +01:00
Anders Schack-Mulligen
ae47339d1a Rust: Accept test changes. 2025-03-25 12:31:05 +01:00
Tom Hvitved
d6d3028e5a Rust: Support Argument[x] MaD source definitions 2025-03-25 09:08:40 +01:00
Tom Hvitved
cf1b19f7c4 Rust: Add test for MaD argument source 2025-03-25 09:06:56 +01:00
Paolo Tranquilli
29b7acfddd Merge pull request #19101 from github/redsun82/rust-fix-main
Rust: accept test changes for now
2025-03-24 16:22:04 +01:00
Tom Hvitved
0f1aee025c Merge pull request #19051 from hvitved/rust/path-resolution-cross-crate
Rust: Path resolution improvements
2025-03-24 14:14:12 +01:00
Paolo Tranquilli
bf32acc198 Rust: accept test changes for now 2025-03-24 13:43:27 +01:00
Tom Hvitved
3f1f37fd5f Address review comments 2025-03-24 10:53:38 +01:00
Simon Friis Vindum
b2fc4f80fb Rust: Adjustments to type inference 2025-03-20 16:38:06 +01:00
Arthur Baars
b10a296a93 Rust: add more path-injection sinks 2025-03-20 16:30:47 +01:00
Paolo Tranquilli
cd15fb3611 Merge pull request #19071 from github/redsun82/codegen-rust-ancestor-order
Rust: preserve ordering in rust generated code
2025-03-20 15:50:48 +01:00
Simon Friis Vindum
659077769b Merge pull request #19062 from paldepind/rust-ti-1
Rust: Improve handling of trait bounds
2025-03-20 14:38:03 +01:00
Tom Hvitved
3142dbb040 Rust: Rework visibility handling in path resolution 2025-03-20 14:14:53 +01:00
Tom Hvitved
b2fc7e771f Rust: Handle super in use statements 2025-03-20 14:14:33 +01:00
Tom Hvitved
57dfbf4faa Rust: Add path resolution test for super in use statement 2025-03-20 14:14:29 +01:00
Tom Hvitved
8044b0d03c Rust: Exclude macro call paths from resolvePath 2025-03-20 14:13:13 +01:00
Tom Hvitved
7c2bafeb17 Rust: Handle self in use statements 2025-03-20 14:13:12 +01:00
Tom Hvitved
8f8f6f74bc Rust: Add use+self path resolution test 2025-03-20 14:13:11 +01:00
Tom Hvitved
c91176116f Rust: Cross-crate path resolution 2025-03-20 14:13:06 +01:00
Tom Hvitved
bd4c85a5bc Rust: Add cross-crate path resolution test 2025-03-20 13:50:20 +01:00
Tom Hvitved
c5106f78ac Rust: Handle pub use reexports in path resolution 2025-03-20 13:50:18 +01:00
Tom Hvitved
6cf83d3a68 Rust: Add path resolution test for reexported items 2025-03-20 13:50:16 +01:00
Tom Hvitved
92528f2b49 Rust: Add debug predicate 2025-03-20 13:50:15 +01:00
Paolo Tranquilli
e2d6643600 Merge pull request #19072 from github/redsun82/rust-fix-canonical-paths-after-rename
Rust: fix canonical paths broken on `StructExpr` and `StructPath`
2025-03-20 13:40:24 +01:00
Paolo Tranquilli
e9b931e2aa Merge branch 'main' into redsun82/codegen-rust-ancestor-order 2025-03-20 13:13:10 +01:00
Arthur Baars
efedfa1fe2 Rust: move optionalStep/Barrier predicates into Cached module 2025-03-20 13:10:38 +01:00
Tom Hvitved
9b58da7e84 Merge pull request #19057 from hvitved/rust/dependency-renaming
Rust: Take dependency renaming into account when extracting the crate graph
2025-03-20 12:51:24 +01:00
Chris Smowton
d362c030b7 Merge pull request #19065 from smowton/smowton/admin/merge-rc317-into-main
Merge rc/3.17 into main
2025-03-20 11:31:03 +00:00
Paolo Tranquilli
b77c13802b Rust: fix canonical paths broken on StructExpr and StructPath
After the rename done in https://github.com/github/codeql/pull/19059,
canonical path extraction was lost on `StructExpr` and `StructPath` as
the identifiers used for the type in the `emit_detached!` macro were not
updated. This fixes that.
2025-03-20 12:16:47 +01:00
Arthur Baars
f5fe531ab6 Rust: remove Stage::ref() trick 2025-03-20 12:15:41 +01:00
Paolo Tranquilli
4110636032 Rust: preserve ordering in rust generated code
This is a small devex improvement to the rust code generator.

Usage of `sorted` in `rustgen.py` was causing the generated code to be
completely reshuffled on renames, which made diffs hard to follow. As an
example see [this generated file diff](https://github.com/github/codeql/pull/19059/files#diff-c938ba77a3398dd4c633ada5702a03477705c24740a2f7d1e40d4b270d8c3f86).

This will make the order deterministically based on the order of
definitions in the schema file. This means that renames will find the
same place in the generated file, and the place in the generated file
will generally be more predictable with respect to the schema.

However, that does mean this change is heavily reshuffling the generated
code.
2025-03-20 12:12:52 +01:00