Ilya Gorbunov
6d092b5f71
Add more reduceOrNull tests
...
- Test for unsigned arrays
- Update binary api dump with the new functions
2019-12-26 19:27:47 +03:00
Alexander Udalov
16db3a8b5f
Fix compiler and IDE tests on Experimental/RequiresOptIn
...
See cdbabf224f , e009c7064e
2019-12-18 14:09:06 +01:00
Abduqodiri Qurbonzoda
b868e6f8da
Rename Appendable methods parameters
2019-12-17 19:04:00 +03:00
Alexander Udalov
896512f7cd
Support KClass.isInstance/cast/safeCast in stdlib-only reflection implementation
...
#KT-14720 Fixed
2019-10-29 15:52:00 +01:00
Alexander Udalov
5c89f2fa54
Support KClass.qualifiedName in stdlib-only reflection implementation
...
#KT-34586 Fixed
2019-10-29 15:51:25 +01:00
Alexander Udalov
c164745301
Support KClass.simpleName in stdlib-only reflection implementation
...
#KT-33646 Fixed
2019-10-29 15:51:21 +01:00
Ilya Gorbunov
a985402507
Introduce ClockMark.hasPassedNow, hasNotPassedNow functions
...
Makes it more clear to use them than comparing elapsed with Duration.ZERO.
2019-08-16 15:29:16 +03:00
Ilya Gorbunov
44195d436e
Rename: Clock.markNow, ClockMark.elapsedNow
...
Add "Now" suffix to the names of functions that depend on the current
time moment.
2019-08-16 15:29:16 +03:00
Ilya Gorbunov
f889d25287
Introduce TestClock.plusAssign(Duration) and hide implementation details
...
TestClock.plusAssign(Duration) is for advancing TestClock time.
Hide reading value, do not allow to provide initial reading,
fix clock unit to nanoseconds at construction time.
2019-08-16 15:28:45 +03:00
Ilya Gorbunov
4de9361c37
Introduce Duration.isPositive method
2019-08-16 15:25:57 +03:00
Alexander Udalov
a7c8fdcbe2
Use Intrinsics.checkNotNull and throw NPE in !! operator generation
...
This method was introduced in c204e8fc67 "just in case" and was never
used. Therefore we're free to change its semantics and use it in all new
generated code (with API version >= 1.4), without even worrying that the
newly used API will leak from inline functions in stdlib when used with
an older API version. Since we agreed to change the type of thrown
exceptions to java.lang.NPE in KT-22275, invoke a new method
throwJavaNpe now which throws that exception instead of KNPE.
Note that the additional method that takes an exception message is still
unused and exists just in case we need to use it in the future. The new
method throwJavaNpe is public also "just in case" we need to invoke it
in the future; currently it's not invoked from the bytecode.
#KT-22275 In Progress
2019-08-12 16:09:23 +02:00
Ilya Gorbunov
f8724654a1
Bit query and bit rotation functions for Int, Long, Short, Byte
...
#KT-12749
2019-07-08 19:09:32 +03:00
Ilya Gorbunov
155dfeaf35
Generate kotlin.time package public API dump
2019-06-18 04:02:35 +03:00
Jake Wharton
af31794f60
Add Locale-accepting overloads for (de)capitalize in JDK stdlib
...
#KT-28933 fixed
2019-05-29 03:35:33 +03:00
Ilmir Usmanov
e7c78d8d7e
Update bootstrap
...
Update reference public API. Before 266976ac1e
suspend inline functions with crossinline parameters were effectively
inline-only. Fixing it exposed suspendCoroutine as public API.
Update jps artifacts after bootstrap.
2019-05-23 09:28:31 +03:00
Ilya Gorbunov
2c26dc3af6
Add simplified overloads of String<->ByteArray/CharArray conversions
...
These overloads cover the most common cases of conversion of the entire
String or Byte/CharArray, avoiding extra index check and branching.
#KT-24810, KT-29265
2019-05-08 02:58:57 +03:00
Abduqodiri Qurbonzoda
c8a4fa58cd
Implement String to/from ByteArray conversion (KT-24810)
2019-05-06 15:54:28 +03:00
Abduqodiri Qurbonzoda
81d2d3cb6a
Implement String to/from CharArray conversion (KT-29265)
2019-05-06 15:54:28 +03:00
Abduqodiri Qurbonzoda
35c6f09886
Implement coerce extension functions for unsigned types
2019-03-15 17:46:48 +03:00
Abduqodiri Qurbonzoda
82002e5e73
Remove implementations of conversions from UByte/UShort to Float/Double
2019-03-12 02:56:44 +03:00
Ilya Gorbunov
6ae5e91930
Move UArraysKt into kotlin.collections.unsigned package
...
Provide UArraysKt class in kotlin.collections for binary compatibility
instead of removed multipart facade class. It contains only non-inline
functions of the latter.
2019-03-08 23:35:40 +03:00
Abduqodiri Qurbonzoda
be6c2d8c7d
Implement min max minOf maxOf functions for unsigned types (KT-30035)
2019-03-08 23:34:36 +03:00
Abduqodiri Qurbonzoda
bf83f0e070
Implement contains extension functions for URanges (KT-26378)
2019-03-08 23:34:35 +03:00
Abduqodiri Qurbonzoda
cb587893c0
Implement sorting extension functions for UArrays
2019-03-08 23:34:35 +03:00
Abduqodiri Qurbonzoda
c42dbb34ca
Implement drop, take & filter extension functions for UArrays
2019-03-08 23:34:35 +03:00
Abduqodiri Qurbonzoda
abb275775e
Implement map, flatMap, zip & groupBy extension functions for UArrays
2019-03-08 23:34:35 +03:00
Abduqodiri Qurbonzoda
7695b5e575
Implement sum extension function for UArrays (KT-28779)
2019-03-08 23:34:34 +03:00
Abduqodiri Qurbonzoda
690e35f11a
Implement reduce, forEach, min & max extension functions for UArrays
2019-03-08 23:34:34 +03:00
Abduqodiri Qurbonzoda
fc85781bfc
Implement asList, slice & sliceArray extension functions for UArrays
2019-03-08 23:34:34 +03:00
Abduqodiri Qurbonzoda
114736c09b
Implement reversing extension functions for UArrays
2019-03-08 23:34:34 +03:00
Abduqodiri Qurbonzoda
92cd84682c
Implement first, last & single extension functions for UArrays
2019-03-08 23:34:34 +03:00
Abduqodiri Qurbonzoda
299fac8e2d
Implement conversion from typed array and collection to UArrays
2019-03-08 23:34:34 +03:00
Abduqodiri Qurbonzoda
876dff6d22
Implement fill extension function for UArrays (KT-28339)
2019-03-08 23:34:33 +03:00
Abduqodiri Qurbonzoda
550c74bb6b
Implement binarySearch method for UArrays (KT-27262)
2019-03-08 23:34:33 +03:00
Abduqodiri Qurbonzoda
6cd9858147
Specialize plus operator for UArrays (KT-28397)
2019-03-08 23:34:32 +03:00
Alexander Udalov
d1e33534db
Implement typeOf intrinsic on JVM
...
#KT-29915 Fixed
2019-03-05 18:16:31 +01:00
Ilya Gorbunov
d4b97d33ef
Introduce kotlin.ExperimentalStdlibApi annotation for prerelease API
...
#KT-30174
2019-03-04 20:47:49 +03:00
Abduqodiri Qurbonzoda
1b6b44c805
Implement conversion between floating point numbers and unsigned integers
...
KT-27108
2019-02-25 21:58:03 +03:00
Ilya Gorbunov
6bcd112062
Drop obsolete artifact kotlin-runtime
...
Remove suppresses used to compile some parts of stdlib
as a non-multiplatform project.
2019-02-18 19:20:30 +03:00
Ilya Gorbunov
811566bbe0
Drop obsolete artifacts kotlin-stdlib-jre7/8
2019-02-18 18:44:35 +03:00
Ilya Gorbunov
27dc160aef
Rename Random companion object to Default
...
#KT-27508
2018-10-11 19:06:12 +03:00
Dmitry Petrov
189b05f8a4
Update testData for public API: companion field visibility in 1.3
2018-10-02 16:20:09 +03:00
Mikhail Zarechenskiy
86141be61f
Add inference annotations to the dumped declarations
2018-09-18 23:28:54 +03:00
Ilya Gorbunov
af29dced98
Make overridden compareTo in unsigned types inline only
2018-09-18 22:25:36 +03:00
Ilya Gorbunov
9e0708e85a
Make most of unsigned operations inline only
2018-09-18 22:25:36 +03:00
Ilya Gorbunov
d793221a7b
Extract unsigned type related extensions to separate classes
...
- Rename class with unsigned number to string conversions to UStringsKt
- Extract Random unsigned extensions to URandomKt
2018-09-18 22:25:36 +03:00
Dmitry Petrov
97999a6415
Update testData for public API tests
...
Internal constructors for UIntProgression and ULongProgression are now
correctly detected as non-public API (because of proper metadata).
2018-09-17 17:28:52 +03:00
Ilya Gorbunov
aac96c476a
Rename sequence and iterator builder functions and their scope class
...
This introduces new functions instead of the existing sequence builders:
- `sequence` instead of `buildSequence`
- `iterator` instead of `buildIterator`
- `SequenceScope` instead of `SequenceBuilder`
The old functions were deprecated with error and made inline-only, and `SequenceBuilder` has been
made a deprecated typealias to `SequenceScope`.
Move sequence builders to `SequencesKt` facade class.
Replace sequence builder usages in stdlib and samples.
#KT-26678
2018-09-16 23:30:35 +03:00
Roman Elizarov
4d3d376db8
InlineOnly Result.getOrNull method
2018-09-16 23:27:46 +03:00
Ilya Gorbunov
7e0a658de7
Change nextInt/Long with range parameters from members to extensions
...
We'd like to fix the implementation of these methods, so we could intrinsify them later
or perform other optimizations that are not possible when these methods are open.
2018-09-14 15:15:52 +03:00