Ian Lynagh
0a0ce1f202
Kotlin: Log when we start and finish writing to TRAP files
2023-10-16 16:14:23 +01:00
Ian Lynagh
adb47399c7
Kotlin: Improve support for TRAP compression options
...
While you could control compression with
CODEQL_EXTRACTOR_JAVA_OPTION_TRAP_COMPRESSION
before, most TRAP files used gzip regardless for compatibility with the
Java extractor. Now Java understands the option too we can use it for
shared TRAP files.
2023-10-12 18:13:06 +01:00
Ian Lynagh
d34b85cf03
Kotlin: Remove 1.4 compatibility
...
We now only build with >= 1.5
2023-10-06 15:17:32 +01:00
Ian Lynagh
4d3863461e
Kotlin: Determine our compression method later
...
This way, we already have a logger at the point that we want to log a
warning.
2023-10-04 18:32:12 +01:00
Ian Lynagh
cc63bb55c2
Kotlin: Change how we handle not supporting Brotli
...
This removes the potential for impossible cases.
2023-10-04 18:32:11 +01:00
Ian Lynagh
f3c5c01ec5
Kotlin: Drop support for 1.4.32
...
We never claimed to support anything < 1.5.0, and compiling with
-language-version 1.4 fails as it's not meant to support sealed classes.
If we build 1.4.32 with -language-version 1.5 using a 2.0 compiler,
then the resulting plugin also fails.
2023-10-02 17:29:10 +01:00
Ian Lynagh
30d7f0cf0a
Merge pull request #14334 from igfoo/igfoo/ext-frag
...
Kotlin: Handle IrExternalPackageFragment properly for more external entities
2023-09-28 20:01:52 +01:00
Ian Lynagh
e9482fb096
Kotlin: Differentiate 2 error messages
2023-09-28 14:59:21 +01:00
Ian Lynagh
5db283e86a
Kotlin: Fix comment
2023-09-28 14:26:02 +01:00
Ian Lynagh
261ae4ea4d
Kotlin: Handle IrExternalPackageFragment properly for more external entities
2023-09-28 12:12:18 +01:00
Ian Lynagh
497d48bd63
Kotlin: Claim to support Kotlin 2
...
We don't fully support it yet, but if we don't claim to support it then
Kotlin fails early.
2023-09-26 17:24:11 +01:00
Ian Lynagh
56b9fa8e9c
Kotlin: Avoid using a possibly-throwing method
2023-09-22 18:15:28 +01:00
Ian Lynagh
52d924924b
Kotlin: Extract LighterAST comments as well as PSI comments
2023-09-14 14:24:52 +01:00
Ian Lynagh
4908188060
Kotlin: Add 1.9.20 support
2023-09-12 18:28:33 +01:00
Ian Lynagh
4d1ceff7df
Kotlin: Fix build
2023-09-12 18:28:33 +01:00
Ian Lynagh
5ea4c44701
Kotlin: Give some more informative errors messages
2023-09-05 12:33:49 +01:00
Ian Lynagh
a2659eecfb
Merge pull request #14018 from igfoo/igfoo/extractor_information_kotlin1
...
Kotlin: Write usesK2 ("uses Kotlin 2") information to the database
2023-09-04 13:38:23 +01:00
Ian Lynagh
181594badb
Kotlin: Add packageFqName and IrSymbolInternals compatibility
...
In master, we need to switch to these, but for building for older
versions we need to add our own support.
Currently the v_1_9_255 files are nto used, but we will need them (in a
differently-named directory) for a future release.
2023-09-01 11:20:58 +01:00
Ian Lynagh
72e08a9277
Kotlin: Tweak the build system
...
You can now make a versions/* directory that the build system doesn't
know about. This can be used to add support for not-yet-supported
versions.
2023-09-01 11:08:54 +01:00
Ian Lynagh
eb59bc04cd
Kotlin: Add missing imports
2023-08-31 19:28:05 +01:00
Ian Lynagh
1ec29bffbb
Kotlin: Don't use deprecated createBlockBody
...
The function that takes a list of statements is hidden in upstream
master.
2023-08-31 19:28:05 +01:00
Ian Lynagh
d511d46cde
Kotlin: Use packageFqName rather than fqName
...
Upstream master says:
error: using 'fqName: FqName' is an error. Please use `packageFqName` instead
2023-08-31 19:28:05 +01:00
Ian Lynagh
c67cc23e07
Kotlin: Write usesK2 information to the database
2023-08-22 12:37:01 +01:00
Ian Lynagh
3b9bd16097
Kotlin: Mark some functions as private
2023-08-15 12:38:47 +01:00
Ian Lynagh
a8b69e5b55
Kotlin: Fix build on old versions
2023-08-15 11:30:23 +01:00
Ian Lynagh
eb27428514
Kotlin: Handle IrExternalPackageFragment when dealing with external decls
2023-08-14 17:37:48 +01:00
Ian Lynagh
72af8ac1e2
Kotlin: Switch to useDeclarationParentOf
...
This lets us handle Kotlin 2 declarations whose parent is an
IrExternalPackageFragment, indicating that they are in a (multi)file
class.
2023-08-14 17:02:49 +01:00
Ian Lynagh
4f336820de
Kotlin: Start handling IrExternalPackageFragment parents
2023-08-14 17:02:48 +01:00
Ian Lynagh
77451de9a3
Kotlin: Fix isExternalDeclaration for Kotlin 2
2023-08-14 15:01:13 +01:00
Ian Lynagh
58da62e244
Kotlin: Handle null parent IDs in getFunctionLabel correctly
2023-08-10 18:49:10 +01:00
Ian Lynagh
0eb6d1c76e
Kotlin: useFunction might return null
2023-08-09 13:45:15 +01:00
Ian Lynagh
3e86c4c39e
Kotlin: Allow extractNewExpr to return null
2023-08-07 18:59:51 +01:00
Ian Lynagh
0d97c1c54a
Merge pull request #13837 from igfoo/igfoo/nullFunLabel
...
Kotlin: Pass on a parentId and remove some redundant braces
2023-08-07 12:19:22 +01:00
Ian Lynagh
01a512b677
Kotlin: Pass on a parentId
2023-07-28 17:46:05 +01:00
Ian Lynagh
e8f4aee1cf
Kotlin: Remove some redundant braces
2023-07-28 17:02:24 +01:00
Ian Lynagh
499bd970d3
Merge pull request #13412 from igfoo/igfoo/json_escape
...
Kotlin: Tweak our JSON escaping
2023-07-28 11:13:51 +01:00
Ian Lynagh
6dedd9286c
Kotlin: Record "file class" info from the compiler
...
We were making file classes when the parent was a file, but not when it
was a class marked as one.
2023-07-11 15:58:42 +01:00
Ian Lynagh
fcf003ceb5
Revert "Kotlin: Remove a use of ObsoleteDescriptorBasedAPI"
...
This reverts commit a50d804ad7 .
2023-06-30 19:32:37 +01:00
Ian Lynagh
a50d804ad7
Kotlin: Remove a use of ObsoleteDescriptorBasedAPI
...
This isn't supported in Kotlin 2 mode, but removing this code doesn't
affect any tests.
2023-06-28 13:48:43 +01:00
Ian Lynagh
4adecf0d15
Merge pull request #13586 from igfoo/igfoo/diag-limit
...
Kotlin: Remove an out-of-date comment
2023-06-27 15:41:47 +01:00
Ian Lynagh
4415c364ac
Merge pull request #13542 from igfoo/igfoo/modality_final
...
Kotlin: Remove an expected-no-getter exception
2023-06-27 15:41:27 +01:00
Ian Lynagh
d588f52262
Kotlin: Remove an out-of-date comment
2023-06-27 13:33:52 +01:00
Ian Lynagh
0d05f50aaa
Kotlin: Remove an expected-no-getter exception
...
We're not sure why it was necessary.
2023-06-22 18:12:13 +01:00
Ian Lynagh
bfd0a19d85
Kotlin: Define DiagnosticTrapWriter, for type safety
...
In some cases, we were writing diagnostics to TRAP files where they
shouldn't be written. Such TRAP files don't define #compilation, so TRAP
import gave errors.
Now we use DiagnosticTrapWriter to get the type system to check that we
are writing diagnostics to the right place.
2023-06-21 18:38:27 +01:00
Ian Lynagh
64e591a823
Merge pull request #13482 from igfoo/igfoo/conc
...
Kotlin: Avoid another cause of ConcurrentModificationException with 1.9
2023-06-19 12:57:25 +01:00
Ian Lynagh
1f538cced3
Kotlin: Handle IrSyntheticBodyKind.ENUM_ENTRIES
...
Generated by Kotlin 1.9 for some of our tests.
2023-06-19 10:36:29 +01:00
Ian Lynagh
096e9a4ba4
Kotlin: Avoid another cause of ConcurrentModificationException with 1.9
2023-06-16 17:06:54 +01:00
Ian Lynagh
d3941ae935
Kotlin: Avoid using deprecated APIs
2023-06-09 18:14:09 +01:00
Ian Lynagh
22fe055e53
Kotlin: Tweak our JSON escaping
...
We were escaping '/', but I don't think there is any need to do so. It
just happens to have a nice escape in the spec. Escaping it might
filenames annoying to work with.
I've also added escaping for the other control characters that we're
meant to escape.
2023-06-08 15:20:30 +01:00
Ian Lynagh
0090429d53
Kotlin: Support 1.9.0
2023-05-31 19:43:45 +01:00