Paolo Tranquilli
9d4a208c0d
Swift: extract MissingMemberDecl
2022-11-09 12:04:42 +01:00
Paolo Tranquilli
235181fb21
Swift: share translateDiagnosticsKind with SwiftDiagnosticsConsumer
2022-11-09 12:00:43 +01:00
Paolo Tranquilli
7bcee6e9a8
Merge branch 'main' into redsun82/swift-decls
2022-11-09 11:59:16 +01:00
AlexDenisov
8756989b4b
Merge pull request #11101 from github/alexdenisov/extractor-errors
...
Swift: extract diagnostics
2022-11-09 11:33:54 +01:00
Paolo Tranquilli
73ad1307ae
Swift: extract PoundDiagnosticDecl
2022-11-09 11:13:55 +01:00
Paolo Tranquilli
b399d8df7e
Swift: extract opaque types and their decls
2022-11-09 09:27:25 +01:00
Geoffrey White
af9ad7b699
Merge branch 'main' into tuples
2022-11-08 21:38:38 +00:00
Paolo Tranquilli
53b7584a90
Merge pull request #11169 from github/redsun82/swift-extract-last-stmts
...
Swift: extract remaining `Stmt`s
2022-11-08 20:51:10 +01:00
Paolo Tranquilli
7939b84380
Merge pull request #11168 from github/redsun82/swift-postfix-expr
...
Swift: extract `PostfixUnaryExpr`
2022-11-08 20:50:45 +01:00
Paolo Tranquilli
cbae72d9da
Swift: remove emoji in test
2022-11-08 17:41:40 +01:00
Paolo Tranquilli
9ee4f8b388
Swift: extract remaining Stmts
...
`FailStmt` are `return nil` in fallible initializers.
`PoundAssertStmt` are an experimental feature for compile time
assertions.
2022-11-08 17:38:17 +01:00
Mathias Vorreiter Pedersen
4cdcebf022
Merge pull request #11161 from geoffw0/localflowsource
...
Swift: Add LocalFlowSource class and a few sources.
2022-11-08 16:12:32 +00:00
Paolo Tranquilli
00d3ff8a18
Swift: extract UnaryPostfixExpr
2022-11-08 17:10:33 +01:00
Tony Torralba
eef4fc3a0a
Apply suggestions from code review
...
Co-authored-by: mc <42146119+mchammer01@users.noreply.github.com >
2022-11-08 15:44:26 +01:00
Paolo Tranquilli
d325a42890
Swift: print unextracted entities
2022-11-08 15:38:53 +01:00
Alex Denisov
3f2f328d87
Swift: put invocation files into a separate folder
2022-11-08 15:32:51 +01:00
Alex Denisov
096469c6fe
Swift: use timestamp + getpid for the invocation filename
2022-11-08 15:26:35 +01:00
Alex Denisov
42004d93f0
Swift: cleanup diagnostic message construction
2022-11-08 15:07:01 +01:00
Alex Denisov
d9b3104c78
Swift: remove unneeded include
2022-11-08 15:03:43 +01:00
Alex Denisov
4f05f083a5
Swift: split SwiftLocationExtractor into h/cpp
2022-11-08 15:02:22 +01:00
Alex Denisov
609c7cf84d
Swift: Rename diagnostics consumer
2022-11-08 14:56:50 +01:00
Geoffrey White
25b4296045
Swift: Rename predicate to avoid confusion.
2022-11-08 13:52:33 +00:00
Alex Denisov
2b8b6d3dc3
Swift: ignore diagnostics for PrintAst
2022-11-08 14:45:56 +01:00
Alex Denisov
e9c4cb227f
Swift: add more diagnostics tests
2022-11-08 14:41:10 +01:00
Alex Denisov
680b7a16fb
Swift: extract location extraction into a separate entity
2022-11-08 14:41:10 +01:00
Alex Denisov
e9da5eecf2
Swift: update test expectations
2022-11-08 14:41:06 +01:00
Geoffrey White
24c8f1d8b5
Swift: Add some local (and remote) flow sources for String.
2022-11-08 13:38:25 +00:00
Alex Denisov
b62a4aae1a
Swift: include null terminators into the invocation file hash
2022-11-08 14:36:28 +01:00
Alex Denisov
433f4e0cb5
Swift: use DbFile/DbLocation
2022-11-08 14:36:28 +01:00
Alex Denisov
288bdc2ee9
Swift: add diagnostics test case
2022-11-08 14:36:28 +01:00
Alex Denisov
b39cf7ea11
Swift: diagnostics: fix bazel build
2022-11-08 14:36:28 +01:00
Alex Denisov
1574e855eb
Swift: consume and store compiler frontend diagnostics
2022-11-08 14:36:28 +01:00
Alex Denisov
62c26f8f27
Swift: add diagnostics to dbscheme
2022-11-08 14:36:25 +01:00
Geoffrey White
e669754d0b
Swift: Also add local flow sources to summary queries.
2022-11-08 13:05:41 +00:00
Geoffrey White
be05b807cd
Swift: Add models-as-data local flow sources as well.
2022-11-08 13:05:41 +00:00
Geoffrey White
0dcb5546a1
Swift: Add a LocalFlowSource and FlowSource class.
2022-11-08 13:05:41 +00:00
Geoffrey White
c5285acb04
Swift: Add more tests for String flow sources.
2022-11-08 13:05:40 +00: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
Rasmus Wriedt Larsen
4895daba85
DataFlow: Add read/store stepIsLocal consistency checks
2022-11-08 13:32:49 +01:00
Paolo Tranquilli
9731048836
Swift: remove an assert from swift headers
...
An interesting byproduct was finding a problematic `assert` in the
Swift headers. An incomplete `FallthroughStmt` was asserting on having
a destination. I did not find any other sensible way of getting rid of
the crash when running in debug mode than to patch the header.
2022-11-08 11:47:12 +01:00
Paolo Tranquilli
fda9d19a97
Swift: replace undefined labels with UnspecifiedElement
2022-11-08 11:47:12 +01:00
Paolo Tranquilli
8d3e6ff8a7
Swift: add label iteration
2022-11-08 11:47:12 +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
Paolo Tranquilli
d6fb6bf036
Swift: customize UnspecifiedElement
2022-11-08 11:40:27 +01:00
Paolo Tranquilli
e17bc6c581
Swift: add UnspecifiedElement
2022-11-08 11:40:27 +01:00
Tony Torralba
4411852e59
Add BitwiseOperation.qll
2022-11-08 11:33:10 +01:00
Paolo Tranquilli
2aa528852e
Swift: add possibility to specify null class
2022-11-08 11:27:14 +01:00
Nora Dimitrijević
7585541514
Merge branch 'main' into swift/js-injection
2022-11-08 11:25:54 +01:00
Nora Dimitrijević
d37ed02e79
Swift: basic Data-related taint flow in query
...
Still TODO: a more comprehensive taint flow model for Data in the libs.
2022-11-08 11:24:53 +01:00
Nora Dimitrijević
66291d3575
Swift: sync tests pass with additional flow steps
...
TODO: Convert those flow steps to taint flow models in the library.
2022-11-08 11:09:55 +01:00