Mathias Vorreiter Pedersen
e98bdbf73f
Merge pull request #9773 from geoffw0/stringlengthconflation4
...
Swift: More improvements to swift/string-length-conflation
2022-07-01 17:46:04 +01:00
Geoffrey White
e38254c05e
Swift: Fix typo.
2022-07-01 17:00:36 +01:00
Geoffrey White
34ffd1aac5
Swift: Support String.Index and flow through * /.
2022-07-01 14:59:50 +01:00
Geoffrey White
d60d2457c2
Swift: Add String.Index.init as a source as as well.
2022-07-01 14:59:50 +01:00
Geoffrey White
bc03f6959c
Swift: Detect String -> NSString results.
2022-07-01 14:59:50 +01:00
Geoffrey White
a306f312cd
Swift: Add a test of converting Range to NSRange.
2022-07-01 14:59:50 +01:00
Geoffrey White
416977dc50
Swift: Add test cases for removeFirst, removeLast.
2022-07-01 14:59:50 +01:00
Paolo Tranquilli
f9143f7855
Swift: fix extraction of empty files
2022-07-01 15:43:16 +02:00
Paolo Tranquilli
3a975174c3
Swift: extract ImportDecl and ModuleDecl
...
As `ASTMangler` crashes when called on `ModuleDecl`, we simply use
its name.
This might probably not work reliably in a scenario where multiple
modules are compiled with the same name (like `main`), but this is left
for future work. At the moment this cannot create DB inconsistencies.
2022-07-01 15:29:30 +02:00
Geoffrey White
68c76006bd
Swift: Allow trivial taint-like flow.
2022-06-30 11:52:57 +01:00
Geoffrey White
0251fb2d35
Swift: Add result annotations to test.
2022-06-30 11:52:44 +01:00
Geoffrey White
2bd25fc589
Swift: Add QLDoc.
2022-06-30 11:52:17 +01:00
Mathias Vorreiter Pedersen
51e3ff9d09
Merge pull request #9736 from github/redsun82/swift-fix-warnings
...
Swift: fix QL warnings about overriding methods
2022-06-30 11:44:44 +01:00
Alex Denisov
5d5f3f82b1
Swift: fix test case
2022-06-30 07:41:28 +02:00
Paolo Tranquilli
d00fec34c3
Merge pull request #9336 from MathiasVP/swift-decls-in-cfg
...
Swift: CFG for local declarations
2022-06-29 15:10:45 +02:00
Mathias Vorreiter Pedersen
e03646aba4
Merge pull request #9737 from geoffw0/arithmetic
...
Swift: Add ArithmeticOperation.qll library
2022-06-29 13:40:20 +01:00
Mathias Vorreiter Pedersen
f35ab7c292
Swift: Accept test changes to the cfg. These happen due to the fixes in 9e0cf62cda.
2022-06-29 12:20:07 +01:00
Mathias Vorreiter Pedersen
15dc08351e
Merge pull request #9747 from MathiasVP/fix-joins-in-swift-cwe-135
...
Swift: Don't join on index in `swift/string-length-conflation`
2022-06-29 11:58:36 +01:00
Geoffrey White
8b7535af81
Swift: Don't use abstract classes.
2022-06-29 11:49:22 +01:00
Geoffrey White
2cf65c7d35
Swift: Autoformat tests.
2022-06-29 11:49:21 +01:00
Geoffrey White
822002d37d
Swift: Missing qldoc.
2022-06-29 11:49:20 +01:00
Mathias Vorreiter Pedersen
cc25e2644f
Swift: Don't join on index in 'swift/string-length-conflation'.
2022-06-29 11:40:46 +01:00
Mathias Vorreiter Pedersen
4356155eeb
Merge branch 'main' into swift-decls-in-cfg
2022-06-29 10:03:34 +01:00
Jeroen Ketema
55e052af26
Merge pull request #9686 from aschackmull/dataflow/no-node-scan
...
Dataflow performance: Avoid node scans
2022-06-29 10:38:56 +02:00
Paolo Tranquilli
296b8cb630
Merge pull request #9719 from github/redsun82/swift-enum-is-case
...
Swift: add EnumIsCase test
2022-06-29 09:55:20 +02:00
Mathias Vorreiter Pedersen
c2e57c3c9b
Swift: Fix 'kind' in 'swift/string-length-conflation'.
2022-06-28 22:33:28 +01:00
Mathias Vorreiter Pedersen
1a7f5db8e2
Swift: Set 'swift/string-length-conflation' to precision high and delete the placeholder query.
2022-06-28 17:01:06 +01:00
Mathias Vorreiter Pedersen
f2ae73b6be
Merge pull request #9738 from geoffw0/misc
...
Swift: Add a Locatable.getFile() shortcut similar to the one in CPP.
2022-06-28 16:44:02 +01:00
Geoffrey White
ff06e3cb6b
Swift: Add a Locatable.getFile() shortcut similar to the one in CPP.
2022-06-28 15:49:49 +01:00
Geoffrey White
8a8a7ead9b
Swift: Add tests for ArithmeticOperation.qll.
2022-06-28 15:34:23 +01:00
Geoffrey White
a5fff9af5d
Swift: Create ArithmeticOperation.qll.
2022-06-28 15:34:15 +01:00
Geoffrey White
9e0cf62cda
Swift: Fix + simplify LogicalOperation.qll.
2022-06-28 15:33:03 +01:00
Paolo Tranquilli
363f7a88a9
Swift: fix QL warnings about overriding methods
...
The `getName` in `Type.qll` was issuing a warning in other generated
classes having a `getName` from a `name` property in `schema.yml`.
To fix the possible inconsistency, `diagnostic_name` is being renamed to
`name` in the schema. Despite the scary doc comment on
`swift::Type::getString` (namely `for use in diagnostics only`), that
seems to be the right generic naming mechanism for types, and it
coincides with the name we were extracting on types with an explicit
`name` property.
In case we find a case where `Type::getString` gives something wrong,
we can probably just patch it on that specific type class.
2022-06-28 16:30:25 +02:00
Paolo Tranquilli
5c6ac2a5f2
Swift: accept test results
2022-06-28 16:15:05 +02:00
Geoffrey White
63376da90f
Swift: Add tests for LogicalOperaion.qll.
2022-06-28 15:04:47 +01:00
Paolo Tranquilli
6ff45d3dbe
Merge main into redsun82/swift-enum-is-case
2022-06-28 16:03:38 +02:00
Paolo Tranquilli
364085a596
Swift: add DotSyntaxCallExpr tests
2022-06-28 15:44:42 +02:00
Paolo Tranquilli
131524d867
Swift: accept test changes
...
These are due to the changes on `toBeTested` that include canonical
types.
2022-06-28 12:16:08 +02:00
Paolo Tranquilli
57981384df
Swift: extract ProtocolComposition- and BuiltinType
2022-06-28 12:01:36 +02:00
Paolo Tranquilli
f2b589743a
Swift: add possibility to collapse class hierarchy in tests
2022-06-28 12:01:36 +02:00
Paolo Tranquilli
9d97fe7f30
Swift: generalize EnumIsCaseExpr test
2022-06-27 17:22:48 +02:00
Paolo Tranquilli
7f694f3b90
Swift: add EnumIsCase test
2022-06-27 16:25:46 +02:00
Mathias Vorreiter Pedersen
41b23572f0
Merge pull request #9673 from geoffw0/stringlengthconflation2
...
Swift: String length conflation query
2022-06-27 10:29:09 +01:00
Paolo Tranquilli
41fb55a7a8
Swift: extract all ReferenceStorageTypes
2022-06-24 18:10:31 +02:00
Geoffrey White
9013d56f37
Swift: Strengthen claim about severity in the qhelp.
2022-06-24 17:09:37 +01:00
Paolo Tranquilli
fd209e57cd
Swift: extract InoutType
2022-06-24 17:29:46 +02:00
Geoffrey White
ef283d9b7a
Swift: Metadata.
2022-06-24 16:20:16 +01:00
Paolo Tranquilli
189a47e30d
Swift: extract VariadicSequenceType
2022-06-24 17:15:45 +02:00
Paolo Tranquilli
346110e8dd
Swift: extract DynamicSelfType
2022-06-24 16:49:58 +02:00
Paolo Tranquilli
4281605ba7
Swift: extract existential types
2022-06-24 16:28:18 +02:00