Tom Hvitved
b7d6165d42
C#: Convert cs/web/xss to a path-problem
2019-08-01 15:58:57 -07:00
Tom Hvitved
5c127ef20d
C#: Fix false positives in cs/unchecked-return-value
2019-07-29 17:32:21 -07:00
Tom Hvitved
b6f3f7866b
C#: Add more tests for cs/unchecked-return-value
2019-07-29 15:40:22 -07:00
Tom Hvitved
8a35813e1c
C#: Unify goto completions
2019-07-05 07:21:34 +02:00
semmle-qlci
0290c79c54
Merge pull request #1486 from hvitved/csharp/inherited-completions
...
Approved by calumgrant
2019-07-04 19:45:25 +01:00
Tom Hvitved
421e75d4c1
C#: Address review comments
2019-07-04 11:57:48 +02:00
semmle-qlci
4f3cbe0029
Merge pull request #1521 from hvitved/csharp/constant-condition-fp
...
Approved by calumgrant
2019-07-01 10:52:14 +01:00
Arthur Baars
af68fd4904
Merge pull request #1408 from calumgrant/cs/suppress-null-expr
...
C#: C#8 Nullable expressions and type annotations
2019-06-28 19:21:46 +02:00
Tom Hvitved
f91e460869
C#: Introduce inherited CFG completions
...
When completions are inherited by elements inside `finally` blocks, we previously
threw away the underlying completion. For example, in
```
try
{
if (b)
throw new Exception();
}
finally
{
if (b)
...
}
```
the completions for `b` inside the `finally` block are `true` and `throw(Exception)`,
where the latter is inherited from the `try` block, with an underlying `false`
completion. Throwing away the `false` completion meant that we were unable to prune
the `false` edge (Boolean CFG splitting).
2019-06-28 15:41:49 +02:00
Tom Hvitved
8d7ea2f49f
C#: Add CFG test that mixes Boolean/finally/catch splitting
2019-06-28 15:41:49 +02:00
Tom Hvitved
db565c5a88
C#: Remove false positives in cs/constant-condition
2019-06-28 11:50:53 +02:00
Tom Hvitved
4da7a17f4b
C#: Add more tests for cs/constant-condition
2019-06-28 11:25:18 +02:00
Tom Hvitved
481bf77d5f
CIL: Speedup consistency tests
...
- Make `InstructionViolation` abstract to avoid computing `getInstructionsUpTo()`
for all instructions in the database.
- Enable `consistency.ql`, which reports all consistency violations, and remove
all other specialized tests.
2019-06-27 13:40:07 +02:00
semmle-qlci
1c25e17812
Merge pull request #1505 from hvitved/csharp/autoformat
...
Approved by calumgrant
2019-06-27 08:03:58 +01:00
semmle-qlci
f58c7cc79c
Merge pull request #1446 from hvitved/csharp/cached-stages
...
Approved by calumgrant
2019-06-27 08:03:24 +01:00
Calum Grant
76454ed68a
C#: Fix formatting of arrays and NullableTypes
2019-06-26 20:24:56 +01:00
Calum Grant
abf43dabe5
C#: Address review comments. Fix up toStringWithTypes(), and deprecate predicates in TypeParameterConstraints.
2019-06-26 20:24:56 +01:00
Calum Grant
35ecb948fc
C#: Fix qltests.
2019-06-26 20:24:55 +01:00
Calum Grant
4aa1947a23
C#: Implement type annotations for nullability, parameter kinds and method returns.
2019-06-26 20:24:55 +01:00
Tom Hvitved
bd03e7a590
C#: Auto format
2019-06-26 19:32:08 +02:00
Tom Hvitved
51d093add0
C#: Address review comments
2019-06-25 17:01:48 +02:00
Calum Grant
a3d5d2c8e4
Merge pull request #1345 from denislevin/denisl/cs/MishandlingJapaneseDatesAndLeapYear
...
C#: Japanese Era and Leap Year checks (Likely Bugs)
2019-06-20 10:21:26 +01:00
Calum Grant
07eb0ec5b2
Merge pull request #1462 from hvitved/csharp/controlflowgraph-depr
...
C#: Remove uses of deprecated `ControlFlowGraph` module
2019-06-19 17:55:04 +01:00
Denis Levin
aab4351efb
A few more changes from code review
2019-06-18 17:49:48 -07:00
Tom Hvitved
a1d7382a67
C#: Update expected test output
2019-06-17 20:07:54 +02:00
Tom Hvitved
f408a6ddfc
Merge pull request #1404 from calumgrant/cs/dispose-not-called-on-throw
...
C#: Improvement to cs/dispose-not-called-on-throw
2019-06-17 11:25:16 +02:00
Tom Hvitved
e70f17f260
C#: Remove uses of deprecated ControlFlowGraph module
2019-06-17 10:23:23 +02:00
semmle-qlci
03cf8ef94f
Merge pull request #1422 from hvitved/csharp/switch-expr-completion
...
Approved by calumgrant
2019-06-17 08:33:43 +01:00
Denis Levin
da2422cb17
Addressed code review comments
2019-06-14 18:25:17 -07:00
Tom Hvitved
946be967f8
C#: Break up a big cached stage into multiple stages
...
- Add `Caching.qll` for controlling caching across multiple files.
- Move `isUncertainRefCall()` out of cached module in `Assignable.qll` to avoid
collapsing with CFG stage.
- Remove dependency on `AlwaysNullExpr` in `NullValue::getAnExpr()` to avoid
collapsing with CFG stage.
- Avoid caching pre-SSA library as it should only be used during the CFG construction
stage.
2019-06-12 16:05:45 +02:00
Calum Grant
d055c85ff0
C#: Exclude case from cs/dispose-not-called-on-throw where the disposable is disposed by a UsingStmt, even when explicitly disposed.
2019-06-11 15:20:27 +01:00
Calum Grant
40481fbf9d
C#: Make SuppressNullableWarningExpr a nonNullValue, and add a test.
2019-06-11 12:45:50 +01:00
Calum Grant
d48ce859eb
C#: Implement nullable warning suppression expressions.
2019-06-11 12:12:29 +01:00
Tom Hvitved
17aad4b0a5
C#: Fix CFG for switch expressions in Boolean/nullness contexts
2019-06-07 15:39:33 +02:00
Tom Hvitved
e538d8e9ac
C#: Add CFG tests for switch expression in Boolean/nullness context
2019-06-07 15:39:28 +02:00
Calum Grant
c88359b9c7
C#: Fix test.
2019-06-05 09:42:48 +01:00
Calum Grant
9678f8eaba
C#: Fix control flow graph for using declaration statements.
2019-06-04 18:10:49 +01:00
Calum Grant
20752c80c9
C#: Address review comments
2019-06-04 18:10:49 +01:00
Calum Grant
d6fac7bfb7
C#: Delete file.
2019-06-04 18:10:49 +01:00
Calum Grant
fa89d2b845
C#: Update stats and test output.
2019-06-04 18:10:49 +01:00
Calum Grant
923fbe4c9e
C#: Implement QL model for using declarations, introducing UsingBlockStmt and a UsingDeclStmt.
2019-06-04 18:10:49 +01:00
Calum Grant
ac3a06f77b
C#: Implement null coalescing assignment operator
2019-06-04 18:10:49 +01:00
Calum Grant
599a5b1eef
C#: Make @local_function @modifiable, make LocalFunction extend Modifiable, and extract modifiers for local functions.
2019-06-04 18:10:49 +01:00
Tom Hvitved
f95dd6bb35
Guard tests
2019-06-03 16:00:22 +02:00
Tom Hvitved
25cb01ffea
C#: Handle discard variable declarations in switch expressions
2019-06-03 15:50:41 +02:00
Tom Hvitved
8c1cab2d03
C#: Simplify extraction of is expressions and case statements
2019-06-03 15:50:41 +02:00
Calum Grant
032a6b1c7c
Merge pull request #1375 from hvitved/csharp/switch-expr-guard
...
C#: Switch expression guards
2019-06-03 11:15:10 +01:00
Calum Grant
5b8c6d4789
Merge pull request #1377 from hvitved/csharp/useless-upcast
...
C#: Teach `cs/useless-upcast` about disambiguating constructor calls
2019-05-31 06:51:39 +01:00
Calum Grant
59a006e59e
Merge pull request #1368 from hvitved/csharp/cil-nullness
...
CIL: Account for multiple `VariableUpdate::getSource()`s in nullness analysis
2019-05-29 20:55:08 +01:00
Tom Hvitved
6b99e1a1bf
C#: Teach cs/useless-upcast about disambiguating constructor calls
2019-05-29 15:16:08 +02:00