Chris Smowton
ba0a05c804
Add pretty-printing for patterns
2023-11-30 11:24:04 +00:00
Chris Smowton
668f445fb4
Fix switchCaseControls and hasBranchEdge to account for mixed patterns and constant cases
2023-11-30 11:24:04 +00:00
Chris Smowton
c1814408f0
Fix guard basic block for switch cases
2023-11-30 11:24:04 +00:00
Chris Smowton
6583c72c5d
Restrict pattern type guards to account for nested record matching failures
2023-11-30 11:24:03 +00:00
Chris Smowton
d40311efe9
Spelling
2023-11-30 11:24:03 +00:00
Chris Smowton
6e868d21bd
Make DefaultCase include NullDefaultCase
2023-11-30 11:24:03 +00:00
Chris Smowton
d2ff1baff0
Replace getDefaultOrNullDefaultCase with getDefaultCase
2023-11-30 11:24:03 +00:00
Chris Smowton
0bb051e08c
First stab at implementing negative type-test logic for pattern-case
2023-11-30 11:24:03 +00:00
Chris Smowton
8fd4f99a39
Fix autoformat comment translocation
2023-11-30 11:24:03 +00:00
Chris Smowton
b11a17db21
Improve change note
2023-11-30 11:24:03 +00:00
Chris Smowton
d7a517a989
Remove needless test options
2023-11-30 11:24:03 +00:00
Chris Smowton
ab9f2a77e4
Move comments
2023-11-30 11:24:03 +00:00
Chris Smowton
cc373e322f
Engineer join order for getLexicallyOrderedRecordField
2023-11-30 11:24:03 +00:00
Chris Smowton
6fb33e0bde
Re-re-factor instanceOfGuarded et al
2023-11-30 11:24:03 +00:00
Chris Smowton
06d5233523
Use SwitchCase.getSelectorExpr
2023-11-30 11:24:03 +00:00
Chris Smowton
b731b8d30a
Simplify PatternExpr definition
2023-11-30 11:24:02 +00:00
Chris Smowton
3d980b1684
Switch to using VariableAssign for instanceof and switch dataflow
2023-11-30 11:24:02 +00:00
Chris Smowton
176adf4376
Move PatternExpr to correct file
2023-11-30 11:24:02 +00:00
Chris Smowton
8f10d29f68
Typo
2023-11-30 11:24:02 +00:00
Chris Smowton
de2b98f4a1
Fix hasNullCase
2023-11-30 11:24:02 +00:00
Chris Smowton
480781b049
autoformat
2023-11-30 11:24:02 +00:00
Chris Smowton
158f4bff7a
Note specific switch bugfix
2023-11-30 11:24:02 +00:00
Chris Smowton
011eb2201e
Add test for ObjFlow over binding patterns
2023-11-30 11:24:02 +00:00
Chris Smowton
4cf511e26a
Add test for virtual-dispatch flow through binding patterns
2023-11-30 11:24:02 +00:00
Chris Smowton
43c935024a
Add test for typeflow propagation through instanceof and pattern-case
2023-11-30 11:24:02 +00:00
Chris Smowton
fa09be0459
Ensure pattern-case and binding-instanceof are covered in all of type, dispatch and object flow
2023-11-30 11:24:02 +00:00
Chris Smowton
88d9caff8c
Unused local query: exclude mandatory declarations
2023-11-30 11:24:02 +00:00
Chris Smowton
91774099fa
Write-only container query: account for implicitly-initialised variables
2023-11-30 11:24:01 +00:00
Chris Smowton
bb6e04456a
Boxed variable query: account for implicit-init variables
2023-11-30 11:24:01 +00:00
Chris Smowton
0e3f6f7873
autoformat
2023-11-30 11:24:01 +00:00
Chris Smowton
9035ba1f30
Fix isImplicitInit; use it in empty-container query
2023-11-30 11:24:01 +00:00
Chris Smowton
7106ec77bc
Fix change note
2023-11-30 11:24:01 +00:00
Chris Smowton
2a6e86633d
Improve qldoc
2023-11-30 11:24:01 +00:00
Chris Smowton
e5fdf4dd50
Update test expectation
2023-11-30 11:24:01 +00:00
Chris Smowton
a335109a20
Note that instanceof with a record pattern doesn't have a type access
2023-11-30 11:24:01 +00:00
Chris Smowton
11444a3ae7
Rename Pattern to PatternExpr to avoid clashing with Regex::Pattern
2023-11-30 11:24:01 +00:00
Chris Smowton
023615386b
Add change note
2023-11-30 11:24:01 +00:00
Chris Smowton
ded8deceaa
Add missing qldoc
2023-11-30 11:24:01 +00:00
Chris Smowton
db5979f1ac
Autoformat upgrade/downgrade scripts
2023-11-30 11:24:01 +00:00
Chris Smowton
1d82756dc8
Fix downgrade script
2023-11-30 11:24:00 +00:00
Chris Smowton
04c9f60d96
Make up some stats for new expressions, setting canonical constructors as common as records and new expression kinds initially rare
2023-11-30 11:24:00 +00:00
Chris Smowton
3cdb1d29f1
Add upgrade and downgrade scripts for latest dbscheme
2023-11-30 11:24:00 +00:00
Chris Smowton
330a5b8c6c
autoformat ql
2023-11-30 11:24:00 +00:00
Chris Smowton
32416f0fdc
Add test for record-pattern instanceof
2023-11-30 11:24:00 +00:00
Chris Smowton
e41da3b10a
Add missing test Java files
2023-11-30 11:24:00 +00:00
Chris Smowton
5b734fe937
Pretty-print AST: handle instanceof with record pattern
2023-11-30 11:24:00 +00:00
Chris Smowton
f037030c26
Adapt instanceof CFG and DFG to general patterns
2023-11-30 11:24:00 +00:00
Chris Smowton
20b97af02f
Implement dataflow for record patterns
...
Strategy: there is now a regular flow step from an instance-of LHS / switch expr to the pattern, 0 or more read steps corresponding to record pattern destructors, and then finally a normal SSA def/use step connecting the binding patterns to their first uses.
2023-11-30 11:24:00 +00:00
Chris Smowton
05addde957
Adapt control-flow graph to record patterns
2023-11-30 11:24:00 +00:00
Chris Smowton
556feb31f0
Autoformat
2023-11-30 11:24:00 +00:00