Mathias Vorreiter Pedersen
b2c7c57815
Swift: Fix expected files after a semantic merge conflict.
2023-08-16 13:52:06 +01:00
Robert Marsh
3d20897725
Merge pull request #13910 from rdmarsh2/rdmarsh2/swift/for-await-cfg
...
Swift: CFG test for for-try-await
2023-08-15 11:16:07 -04:00
Robert Marsh
7053c62c41
Swift: update and sync tests
2023-08-11 18:52:37 +00:00
Alex Denisov
cebaca328e
Swift: 'ParsedSequence' lacks proper types and yields 'Unresolved' AST nodes
2023-08-08 14:41:15 +02:00
Mathias Vorreiter Pedersen
89aa86a1d6
Merge pull request #13741 from rdmarsh2/rdmarsh2/swift/array-content-flow
...
Swift: add DataFlow::Content for arrays
2023-08-02 17:37:40 +02:00
Alex Denisov
9d643ae1ed
Swift: record CFG incosistency
2023-08-01 15:06:04 +02:00
Alex Denisov
6667d9e45c
Swift: SubExpr may yield unresolved nodes in certain cases while MatchedExpr is always resolved
2023-08-01 14:15:33 +02:00
Robert Marsh
22ae430e65
Swift: accept more test changes from hiding InOutExpr
2023-07-28 20:43:25 +00:00
Alex Denisov
ea5eda0f22
Swift: adjust test expectations
2023-06-27 17:21:56 +02:00
Alex Denisov
0479ef5b9c
Merge remote-tracking branch 'origin/rc/3.10' into alexdenisov/rc3.10_mergeback
2023-06-16 10:13:23 +02:00
Paolo Tranquilli
396b57696c
Swift: minimal 5.8 compatibility
2023-06-14 16:17:44 +02:00
Nora Dimitrijević
8ccbad601b
Swift: PrintAst test changes
2023-06-06 16:54:47 +02:00
Arthur Baars
490d22d123
Merge remote-tracking branch 'upstream/main' into post-release-prep/codeql-cli-2.13.3
2023-05-30 21:31:28 +02:00
Paolo Tranquilli
7b76aa34bd
Swift: fix CFG inconsistency on TapExpr
2023-05-25 13:05:21 +02:00
Paolo Tranquilli
63fb0581c2
Swift: accept inconsistencies for now
2023-05-24 20:09:46 +02:00
Paolo Tranquilli
e513af1bcf
Swift: add CFG and PrintAst consistency queries, enabling them in CI
2023-05-24 18:10:08 +02:00
Paolo Tranquilli
9a0f87434e
Swift: remove unneeded properties from InterpolatedStringLiteralExpr
...
These properties were unused in the QL library (hence the full
upgrade/downgrade compatibility).
2023-05-22 15:28:54 +02:00
Paolo Tranquilli
de03bdc235
Swift: fix hidden AST getters
...
For consistency with the C/C++ QL library, getters of AST elements
within the hidden AST should not themselves skip other hidden AST
elements.
2023-05-22 09:57:48 +02:00
Nora Dimitrijević
91a151ec2a
Swift: update tests
2023-04-26 15:47:20 +02:00
Geoffrey White
49dccaa89d
Swift: Fix other tests.
2023-04-19 14:16:24 +01:00
Alexandre Boulgakov
35a2d55d18
Swift: Extract structured keypath components.
...
Changes in swift/ql/lib are generated by swift/codegen without manual intervention.
2023-04-11 13:34:17 +01:00
Alexandre Boulgakov
2b1dea56b5
Swift: Add error query to AST tests.
...
Preexisting errors are left to be fixed later.
2023-04-11 13:34:16 +01:00
Nora Dimitrijević
c2e9ffab63
Swift: add EnumElementExpr + Pattern.getMatchingExpr()
2023-03-27 23:01:24 +02:00
Nora Dimitrijević
5419e65e01
Swift: add NamedPattern.getVarDecl()
2023-03-27 23:01:24 +02:00
Nora Dimitrijević
feb8243d5f
Swift: move BindingPattern to the hidden AST
2023-03-27 23:01:24 +02:00
Geoffrey White
f6e7837cb8
Swift: Extend the PrintAST test as well.
2023-03-10 18:28:11 +00:00
Geoffrey White
8624098318
Swift: sync identical files.
2023-02-10 15:24:57 +00:00
Geoffrey White
224bc9381a
Swift: Fix ConditionElement.toString().
2023-02-09 21:15:36 +00:00
Alex Denisov
712c25e6f4
Swift: extract availability info
2023-02-07 14:26:39 +01:00
Nora Dimitrijević
50e5b29eb7
Swift: all Callables can have captures [codegen'd]
2023-02-02 11:56:51 +01:00
Nora Dimitrijević
d230431006
Swift: extract closure captures (codegen'd part)
2023-02-02 11:35:49 +01:00
Nora Dimitrijević
f3ebb6e03b
Swift: MethodLookupExpr.getMethodRef() [codegen'd]
...
This refactors SelfApplyExpr.getFunction() as MethodLookupExpr().getMethodRef().
This is simpler, because we are not hiding DeclRefExprs or reinventing hidden AST resolution.
2022-12-20 23:09:02 -05:00
Nora Dimitrijević
15d5674d12
Swift: update .expected files based on last commit
2022-12-14 14:28:00 -05:00
Paolo Tranquilli
7645d4d928
Swift: remove ModuleDecl from PrintAst test
2022-12-08 17:31:48 +01:00
Nora Dimitrijević
91edeacb9f
Swift: update .expected test files
2022-11-29 19:39:48 +01:00
Paolo Tranquilli
d3ff4908e6
Merge branch 'main' into redsun82/swift-error-element
2022-11-11 14:05:47 +01:00
Paolo Tranquilli
41977d1dbb
Swift: implement extraction of new properties
2022-11-11 12:49:48 +01:00
Paolo Tranquilli
3de650e19d
Swift: make toBeTested and shouldPrint propagate to children
2022-11-11 12:49:18 +01:00
Paolo Tranquilli
f5b198b8b7
Swift: fix dangling test reference
2022-11-10 17:50:22 +01:00
Paolo Tranquilli
552c5249ac
Merge pull request #11131 from github/redsun82/swift-incomplete-ast
...
Swift: deal with incomplete ASTs
2022-11-08 14:01:58 +01:00
Paolo Tranquilli
450a4a04af
Swift: add incomplete ast test
...
The test was inspired by locally running the query against files in
https://github.com/apple/swift/tree/main/test/Parse
A query for missing elements was also added to the AST tests, expecting
nothing to be found.
2022-11-08 11:46:07 +01:00
Tony Torralba
4411852e59
Add BitwiseOperation.qll
2022-11-08 11:33:10 +01:00
Paolo Tranquilli
21adcca065
Swift: add bitwise ops to PrintAst test
2022-11-08 08:53:36 +01:00
Paolo Tranquilli
c8cb30f76e
Swift: refactor StmtVisitor to use translations
...
Also make `visit` in `SwiftDispatcher` work on `const` pointers.
Also, fixed a bug where the guard of a `CaseLabelItem` was not being
extracted, hence the test updates.
2022-11-03 18:16:53 +01:00
Paolo Tranquilli
4702271102
Swift: add cfg.swift to AST tests
2022-11-03 18:16:53 +01:00
Paolo Tranquilli
69dfdf5a34
Swift: fix IfConfigDecl in QL libraries
...
This fixes `IfConfigDecl` for both the AST printer and control flow
libraries.
It turns out that the active lements of an `IfConfigDecl` are already
listed in the enclosing scope (like a `BraceStmt`), so they should not
be listed as children, and `IfConfigDecl` can be jsut a leaf in the
control flow.
2022-09-21 12:12:55 +02:00
Paolo Tranquilli
2234070bfe
Swift: ...and accept the test
2022-09-02 15:36:46 +02:00
Paolo Tranquilli
c842ae40f6
Swift: make node properties consistent with other languages
2022-09-02 15:31:37 +02:00
Paolo Tranquilli
e3e9774956
Swift: print conversions similarly to C++
2022-09-02 15:31:37 +02:00
Paolo Tranquilli
30049f622d
Swift: move new code down in tests
2022-08-31 11:38:32 +02:00