Commit Graph

1400 Commits

Author SHA1 Message Date
Tamas Vajk
a5415c9c8a Kotlin: Fix array indexer extraction 2022-09-01 11:12:14 +02:00
Ian Lynagh
e4ff25099b Kotlin: Be more permissive
I think we'll end up giving a warning/error later, but that's better
than having a cast throw now.
2022-08-31 18:09:36 +01:00
Ian Lynagh
86034dc602 Kotlin: Add a type signature 2022-08-31 18:05:30 +01:00
Ian Lynagh
c8deb72ede Kotlin: Refactor extractConstructorCall
Avoids some casts.
2022-08-31 16:53:59 +01:00
Ian Lynagh
eca28af883 Kotlin: Removed a couple of casts from extractExpression 2022-08-31 15:34:18 +01:00
Ian Lynagh
6d00860cc1 Kotlin: Refactor kotlinFunctionToJavaEquivalent
Avoids a cast.
2022-08-31 15:03:30 +01:00
Tamás Vajk
bf7437fd2e Merge pull request #10224 from tamasvajk/kotlin-comment-fixes
Kotlin: Fix issues in comment extraction
2022-08-31 14:22:09 +02:00
Ian Lynagh
b5f9fbe247 Merge pull request #10228 from igfoo/igfoo/useSimpleType
Kotlin: Refactor useSimpleType to avoid some casts
2022-08-31 11:32:35 +01:00
Ian Lynagh
da7d2709d9 Merge pull request #10227 from igfoo/igfoo/extractStaticTypeAccessQualifier
Kotlin: Refactor extractStaticTypeAccessQualifier
2022-08-31 11:32:26 +01:00
Tamas Vajk
0cbb73a47e Improve code quality 2022-08-31 09:02:35 +02:00
Ian Lynagh
6f82b06bd7 Kotlin: Implement and use singleOrNullSubType
Pulls another cast out into a utility function.
2022-08-30 18:31:01 +01:00
Ian Lynagh
a07be192fa Kotlin: Refactor useSimpleType to avoid some casts 2022-08-30 17:55:57 +01:00
Ian Lynagh
3459e5e432 Kotlin: Refactor extractStaticTypeAccessQualifier
Avoids a cast
2022-08-30 17:06:13 +01:00
Tamas Vajk
1bc105aff6 Kotlin: adjust log messages and severities in comment extraction 2022-08-30 15:45:25 +02:00
Tamas Vajk
5418c95a01 Kotlin: minor refactoring in comment extraction 2022-08-30 15:43:48 +02:00
Tamas Vajk
9ced14672d Kotlin: Assign container class as the owner of init block comments 2022-08-30 15:37:55 +02:00
Ian Lynagh
f5d43b80ed Merge pull request #10193 from igfoo/igfoo/extractClassSupertypes
Kotlin: Small simplification
2022-08-30 11:52:02 +01:00
Ian Lynagh
f118b39844 Merge pull request #10192 from igfoo/igfoo/array
Kotlin: Remove another cast
2022-08-30 11:51:48 +01:00
Ian Lynagh
a5893f38c5 Merge pull request #10189 from igfoo/igfoo/substituteTypeAndArguments
Kotlin: Remove a cast from substituteTypeAndArguments
2022-08-30 11:51:39 +01:00
Ian Lynagh
d6bdc8c711 Merge pull request #10178 from igfoo/igfoo/AnyDbType
Kotlin: Add AnyDbType
2022-08-30 11:51:25 +01:00
Ian Lynagh
4cd7bf2ebb Kotlin: Small simplification
Also removes a cast
2022-08-26 16:28:10 +01:00
Ian Lynagh
d2a5281d94 Kotlin: Remove another cast 2022-08-26 15:59:26 +01:00
Ian Lynagh
131632e7c1 Kotlin: Remove a cast from substituteTypeAndArguments
It looks like it was safe, but it was hard to see why, and may
become unsafe following future kotlinc changes.
2022-08-26 13:06:05 +01:00
Tamás Vajk
4f5c06fed7 Merge pull request #10169 from tamasvajk/kotlin-array-iterator
Kotlin: fix array iterator extraction
2022-08-26 08:33:52 +02:00
Ian Lynagh
5be8e45d09 Kotlin: Add AnyDbType
All DbType* types extend it, and `Label`s require their argument to be a
subtype of it.
2022-08-25 16:40:27 +01:00
Ian Lynagh
2e2621adad Merge pull request #10154 from igfoo/igfoo/findSubType
Kotlin: Implement and use fun <T,reified S: T> Iterable<T>.findSubType
2022-08-25 12:57:46 +01:00
Ian Lynagh
12eab3d7f0 Kotlin: Specialise findSubType to IrDeclaration
We only use it on that type, and this makes the uses a bit quieter.
2022-08-25 10:11:19 +01:00
Tamas Vajk
15305fd9bb Kotlin: Fix iterator extraction of IntArray, BooleanArray, ... 2022-08-25 11:05:17 +02:00
Tamas Vajk
7196fdd475 Kotlin: fix array iterator extraction to work outside of for loops 2022-08-25 09:23:34 +02:00
Ian Lynagh
b485706fde Kotlin: Remove the last not-null-expressions 2022-08-24 14:39:03 +01:00
Ian Lynagh
e4f66b8aa7 Kotlin: Refactor writeUpdateInPlaceExpr
In tryExtractArrayUpdate we need to know if writeUpdateInPlaceExpr will
succeed before we start writing any TRAP.
2022-08-24 14:31:10 +01:00
Ian Lynagh
31e1230c64 Kotlin: Remove another not-null-expr 2022-08-24 12:51:15 +01:00
Ian Lynagh
20ac15d549 Merge pull request #10152 from igfoo/igfoo/not-null-exprs
Kotlin: Remove more not-null expressions
2022-08-24 12:18:45 +01:00
Ian Lynagh
4cd90a15d0 Kotlin: Use findSubType in KotlinUsesExtractor too 2022-08-24 12:16:16 +01:00
Ian Lynagh
28d95f4d99 Kotlin: Implement and use fun <T,reified S: T> Iterable<T>.findSubType
We had a lot of uses of find which looked for a subtype, but then had to
cast (seemingly unsafely) the result to that subtype. This pulls all the
casts out into a utility function.
2022-08-24 12:10:53 +01:00
Ian Lynagh
b5f20e40fc Kotlin: Remove some more not-null-expressions 2022-08-24 11:13:27 +01:00
Ian Lynagh
8fe59e7ebc Kotlin: Remove another not-null-expr 2022-08-24 11:09:31 +01:00
Ian Lynagh
01f27ea331 Kotlin: Remove another not-null-expr 2022-08-24 11:07:10 +01:00
Ian Lynagh
940f18f5ae Kotlin: Remove another not-null-expr 2022-08-24 10:59:15 +01:00
Ian Lynagh
44501f5318 Kotlin: Remove another not-null-expr 2022-08-24 10:57:36 +01:00
Ian Lynagh
da7b7ce9f5 Kotlin: Remove some not-null-exprs 2022-08-24 10:55:31 +01:00
Ian Lynagh
623d87aaca Merge pull request #10142 from igfoo/igfoo/not-null-expr
Kotlin: Remove some more non-null-expressions
2022-08-24 10:37:37 +01:00
Ian Lynagh
8b4cf295bc Merge pull request #10110 from igfoo/igfoo/compression
Kotlin: Add support for TRAP compression
2022-08-24 10:37:20 +01:00
Tamás Vajk
ecde0abc04 Merge pull request #10091 from tamasvajk/kotlin-data-class
Kotlin: Identify data classes during extraction
2022-08-24 08:45:41 +02:00
Ian Lynagh
910372bfb7 Kotlin: Refactor CallableReferenceHelper
This removes some non-null-expressions, and also makes the code more
robust and easier to understand.
2022-08-23 15:24:13 +01:00
Ian Lynagh
d3a8060e34 Kotlin: Remove another not-null-expr in the extractor 2022-08-23 12:05:14 +01:00
Ian Lynagh
98dd2448ff Kotlin: Remove a not-null-expr from the extractor 2022-08-23 11:49:55 +01:00
Ian Lynagh
51ada5c2af Merge pull request #10130 from igfoo/igfoo/non-null-exprs
Kotlin: Fix some more not-null-exprs in the extractor
2022-08-23 10:49:45 +01:00
Tamás Vajk
aa0ff2b53f Merge pull request #10129 from tamasvajk/kotlin-fix-comment-type-alias
Kotlin: Extract type alias doc comments
2022-08-22 16:10:50 +02:00
Ian Lynagh
d5b414f163 Kotlin: Fix some more not-null-exprs in the extractor 2022-08-22 14:16:58 +01:00