Граф коммитов

2980 Коммитов

Автор SHA1 Сообщение Дата
Paolo Tranquilli 6d85d0d0f7
Merge pull request #13991 from github/redsun82/swift-use-concepts
Swift: use C++20 constraints and concepts to simplify code
2023-08-21 15:45:44 +02:00
Jeroen Ketema 2d0f73d7c2
Merge pull request #13881 from jketema/shared-taint-tracking
Introduce shared taint tracking library
2023-08-21 12:45:49 +02:00
Paolo Tranquilli bda516e9ea C++: tweak dispatcher clauses 2023-08-21 10:01:45 +02:00
Paolo Tranquilli b78f12481f Swift: tweak priority of location information sources 2023-08-18 15:18:48 +02:00
Paolo Tranquilli 386dedb9df Swift: fix location extractor hitting swift assertion 2023-08-18 14:21:30 +02:00
Paolo Tranquilli c17a582b34 Revert "Swift: upgrade clang-formatting to 15.0.7"
This reverts commit 970b3d06be.
2023-08-18 13:59:41 +02:00
Paolo Tranquilli 3c4e755233 Swift: fix macOS not having `std::ranges::sized_range` 2023-08-18 10:18:53 +02:00
Paolo Tranquilli 8b3e32fa97 Swift: add missing include 2023-08-18 09:10:44 +02:00
Paolo Tranquilli 53ed39065c Swift: tweak location extractor using new concept 2023-08-18 06:45:11 +02:00
Paolo Tranquilli eb8997dc7a Swift: fix `print_unextracted` 2023-08-18 06:44:42 +02:00
Paolo Tranquilli 3de7b75853 Swift: remove uneeded include 2023-08-17 17:36:36 +02:00
Paolo Tranquilli 970b3d06be Swift: upgrade clang-formatting to 15.0.7 2023-08-17 17:24:42 +02:00
Paolo Tranquilli 7c764f3b50 Swift: use C++20 constraints and concepts to simplify code
This simplifies several instances of metaprogramming by leveraging
[constraints and concepts from C++20][1]. This:
* gets rid of `std::enable_if` by usage of `requires`, making it more
  readable and yield better compiler messages.
* uses `requires` instead of `static_assert` to enforce `TrapLabel`
  typing
* simplifies all compile-time tests for validity of a given expression
* uses some standard library concepts where possible
* generalizes and simplifies `SwiftLocationExtractor`

Notice that in order to use the `std::derived_from` concept, `virtual`
inheritance had to be added to the label tags, because diamond
inheritance is a problem otherwise. That's because
`std::derived_from<T, U>` requires that `T*` be convertible to `U*`,
which is false if there are multiple non-virtual inheritance paths from
`U` to `T`. As tags never get actually instantiated, there is no runtime
performance penalty in using `virtual` inheritance.

[1]: https://en.cppreference.com/w/cpp/language/constraints
2023-08-17 17:24:42 +02:00
Paolo Tranquilli 75cc1d8f75 Swift: fix version check macro to be lexicographic 2023-08-17 12:19:28 +02:00
Jeroen Ketema 33e8310625
Merge branch 'main' into shared-taint-tracking 2023-08-17 00:14:25 +02:00
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
Mathias Vorreiter Pedersen fec9626fe7
Merge pull request #13836 from github/alexdenisov/unresolved-dot-exprs
Swift: 'ParsedSequence' lacks proper types and yields 'Unresolved' AST nodes
2023-08-15 09:14:39 +01:00
Geoffrey White b6dc2acc71 Merge branch 'main' into typegetname 2023-08-14 10:46:14 +01:00
Robert Marsh 7053c62c41 Swift: update and sync tests 2023-08-11 18:52:37 +00:00
Henry Mercer 1213eba630
Merge branch 'main' into post-release-prep/codeql-cli-2.14.2 2023-08-11 13:54:55 +01:00
Robert Marsh 36bdadfc36
Merge pull request #13933 from geoffw0/madtuples
Swift: Models-as-data support for tuple content
2023-08-10 14:17:45 -04:00
github-actions[bot] 432c21d4fb Post-release preparation for codeql-cli-2.14.2 2023-08-09 18:45:18 +00:00
Geoffrey White c20a17e7b7 Swift: Update the consistency test .expecteted as well. 2023-08-09 15:47:28 +01:00
Geoffrey White 23f0dd5542 Swift: Support MAD tuple content flow. 2023-08-09 15:08:11 +01:00
Geoffrey White b4b2338144 Swift: Test for MAD tuple content flow. 2023-08-09 14:41:32 +01:00
Geoffrey White 131b2b3e0c Swift: Change note. 2023-08-09 09:25:43 +01:00
Geoffrey White 09346c76e7 Swift: Add models. 2023-08-09 09:25:43 +01:00
AlexDenisov fa729faa0a Revert "Swift: Route compiler diagnostics through our log." 2023-08-09 10:02:59 +02:00
Geoffrey White cb6aed18f3 Swift: Add tests. 2023-08-08 22:29:53 +01:00
Geoffrey White 2b0fcab182 Swift: Update test annotations following merge. 2023-08-08 16:06:52 +01:00
Geoffrey White e9f0b535ea Merge branch 'main' into forceunwrap 2023-08-08 16:03:31 +01:00
Alex Denisov cebaca328e Swift: 'ParsedSequence' lacks proper types and yields 'Unresolved' AST nodes 2023-08-08 14:41:15 +02:00
AlexDenisov 75dad4764f
Revert "Swift: Route compiler diagnostics through our log." 2023-08-08 11:25:13 +02:00
Geoffrey White 022a06659c
Merge pull request #13838 from rdmarsh2/rdmarsh2/swift/set-content
Swift: add SetContent for data flow
2023-08-07 19:15:30 +01:00
github-actions[bot] 79c90fa36a Release preparation for version 2.14.2 2023-08-07 18:08:52 +00:00
Robert Marsh 65fbcc570c Swift: CFG test for for-try-await 2023-08-07 17:44:57 +00:00
Robert Marsh 07650af357 Swift: accept test for CollectionContent rename 2023-08-07 15:04:21 +00:00
Robert Marsh 146c50049c
Finish CollectionContent rename
Co-authored-by: Geoffrey White <40627776+geoffw0@users.noreply.github.com>
2023-08-07 10:26:40 -04:00
Jeroen Ketema 8b6a7985db
Refactor the traint-tracking library to follow the dataflow library refactoring 2023-08-07 15:23:15 +02:00
Jeroen Ketema 5d2984b7a5
Merge branch 'main' into shared-taint-tracking 2023-08-07 15:22:29 +02:00
Geoffrey White dc98dec5b6 Swift: Change note. 2023-08-07 13:16:00 +01:00
Geoffrey White ab3f3d03c5 Swift: Model taint into optionals via ForceValueExpr. 2023-08-07 13:11:29 +01:00
Tom Hvitved 34864e1077 Swift: Adjust to data flow refactor 2023-08-07 11:35:23 +02:00
Jeroen Ketema 747cd1745a
Update all languages to use the shared taint-tracking library 2023-08-04 22:53:25 +02:00
Robert Marsh 3ebbb80a9e Swift: Change note for CollectionContent 2023-08-04 20:19:35 +00:00
Robert Marsh 10bbf441dc Swift: QLDoc for Set.qll 2023-08-04 20:17:56 +00:00
Robert Marsh ccc3094267 Swift: autoformat 2023-08-04 20:17:08 +00:00
Geoffrey White c7fb8de5f9 Swift: Test ForceValueExpr content reads. 2023-08-04 21:15:15 +01:00
Robert Marsh 6f38769a9b Swift: rename SetContent to CollectionContent 2023-08-04 18:46:43 +00:00