Ilya Gorbunov
1036448fcd
Improve the documentation of MatchGroupCollection.
...
#KT-7938 Fixed
2015-06-04 20:51:08 +03:00
Ilya Gorbunov
009baa11fc
Specific wording in exception message for String methods.
2015-06-04 16:45:55 +03:00
Ilya Gorbunov
a1d8e9d633
Provide dropLast and takeLastWhile methods. Optimize special cases of drop/take/dropLast/takeLast (when n is equal to zero or size of collection).
2015-06-04 16:32:25 +03:00
Ilya Gorbunov
9f85fa9720
Make proposed split replacement equivalent in behavior with additional dropLastWhile call.
...
#KT-7887
2015-06-04 16:32:23 +03:00
Ilya Gorbunov
9b17220baa
Provide dropLastWhile for Arrays, Lists and Strings.
2015-06-04 16:32:21 +03:00
Ilya Gorbunov
705c9089f0
Provide replacement for methods deprecated in favor of SAM-constructors.
...
Provide replacement for isNotEmpty on nullable receiver.
JS: Provide SAM-like constructor for Runnable.
2015-06-04 16:32:19 +03:00
Ilya Gorbunov
13c89b7ae9
Provide lineSequence() extension method instead of BufferedReader.lines() in order not to conflict with JDK8 instance method with the same name.
2015-06-04 16:32:17 +03:00
Ilya Gorbunov
0302dd06f7
Do not call mkdirs when destination file of copyTo doesn't have any parent directory.
...
#KT-7888 Fixed
2015-06-02 15:50:47 +03:00
Ilya Gorbunov
64b2e37436
Deprecate meaningless or vague-defined operations with Char operands: downTo.
2015-06-01 00:55:45 +03:00
Dmitry Jemerov
443eabf88a
make Dokka happy by sorting imports of Java classes
2015-05-28 17:53:12 +02:00
Dmitry Jemerov
8f0f02fc59
correct some errors and omissions in stdlib doc comments
2015-05-28 14:38:36 +02:00
Dmitry Jemerov
0e5b6c41dd
use new syntax for annotations
2015-05-28 14:14:05 +02:00
Ilya Gorbunov
802ca5476d
Clarify requirements for limit parameter in split method. Provide replacement for deprecated split(regex: String).
2015-05-27 23:28:06 +03:00
Ilya Gorbunov
ea85290939
Annotate deprecated members with proposed replacement.
2015-05-27 22:29:37 +03:00
Ilya Gorbunov
fa24db435d
Stdlib documentation: clarified toMap behavior when a duplicate key is encountered.
2015-05-27 22:29:33 +03:00
Ilya Gorbunov
1fb4183bbb
Prettify kdocs in stdlib, part 2.
2015-05-27 22:16:19 +03:00
Ilya Gorbunov
5c8c58f702
Prettify kdocs in stdlib, part 1.
2015-05-27 22:16:17 +03:00
Ilya Gorbunov
ae60f7a32f
Prettify kdocs and exception messages in the generated code.
2015-05-27 22:16:15 +03:00
Valentin Kipyatkov
b256329287
Added "ReplaceWith" to deprecated library functions
2015-05-27 16:15:50 +03:00
Valentin Kipyatkov
5c445ca003
DeprecatedSymbolUsageFix: dealing with dropping arguments with potential side effects + stdlib's "let" has no receiver type bound
2015-05-27 16:15:47 +03:00
Dmitry Jemerov
1188e57597
rename @overloads annotation to @jvmOverloads
2015-05-27 12:23:08 +02:00
Ilya Gorbunov
5f319e69d8
Restore String.split(String, Int) overload and make it deprecated.
2015-05-27 00:36:30 +03:00
Ilya Gorbunov
310666a617
Deprecate times method taking integer and function. Provide top-level repeat method instead.
...
#KT-7074 Fixed.
2015-05-26 23:23:37 +03:00
Ilya Gorbunov
45c82f2844
map(): Take into account size of collection being transformed when allocating ArrayList.
...
#KT-7832 Fixed.
2015-05-26 23:23:36 +03:00
Ilya Gorbunov
c9afb407f1
Provide isNotEmpty() extension function for Maps.
2015-05-26 23:23:34 +03:00
Ilya Gorbunov
01a0348685
Remove deprecated size property usage from generated code.
2015-05-26 23:23:32 +03:00
Ilya Gorbunov
1cf4a407d1
JS: Provide MIN_VALUE and MAX_VALUE member constants for Double and Float companion objects.
...
JVM: Make MIN_VALUE and MAX_VALUE not an extension but member constant properties of Double and Float companion objects.
2015-05-26 00:26:19 +03:00
Ilya Gorbunov
4fd1b46e91
Refactor JS tests: unified package name, test JS specific map implementations only in JS.
...
Add required files to build StdLibTestToJSTest.
Remove tests StdLibMapJsTest and StdLibSetJsTest because they are tested elsewhere.
2015-05-24 05:07:01 +03:00
Ilya Gorbunov
c95ba4da8e
Tests for specialized primitive implementations of sets and maps in JS.
2015-05-24 05:06:51 +03:00
Ilya Gorbunov
ebe578dbc5
Tests to ensure the behavior of the specialized empty List, Set, Map implementations is same as of non-specialized ones.
2015-05-24 05:03:46 +03:00
Ilya Gorbunov
edc471c8ec
Optimize the implementation of emptyList, emptySet and emptyMap and make them serializable.
...
Specialized implementations of singleton List, Set and Map are used in JVM.
#KT-6682 Fixed
#KT-7104 Fixed
#KT-4840 Fixed
2015-05-24 05:03:36 +03:00
Ilya Gorbunov
0efaedd32c
Rename files to avoid having identically named files in the same package, which sometimes may confuse debugger.
2015-05-22 18:08:28 +03:00
Ilya Gorbunov
33f5158170
Fix deprecated replaceAll and replaceFirst usages in stdlib tests and tools.
2015-05-22 16:13:55 +03:00
Ilya Gorbunov
6516c74a1a
Revert back 2nd stage of split semantics change and restore deprecated String.split(String).
2015-05-21 23:13:16 +03:00
Michael Nedzelsky
34100fff99
fix maven tests: NoInternalVisibilityInStdLibTest.kt
2015-05-21 02:46:44 +03:00
Ilya Gorbunov
6a3cb0eff8
Provide distinctBy(keySelector) method for collections and sequences.
...
Implement distinct() and toMutableSet() for sequences.
Breaking change: distinct() now returns List instead of Set.
#KT-5834 Fixed
#KT-6063 Fixed
2015-05-20 19:28:47 +03:00
Ilya Gorbunov
46d91b2606
Add test for toMap with key selector and value transform.
2015-05-20 19:28:45 +03:00
Ilya Gorbunov
85e637b1e7
Revert toArrayList for primitive arrays back to trivial implementation.
...
Use newly introduced Int.MAX_VALUE in JS.
Inline mapCapacityForValues function.
Precalculate capacity of linked hash set being created with toMutableSet function.
2015-05-20 19:28:44 +03:00
Danny Thomas
7ce0487b7e
Collection performance improvements
...
Lists
- For arrays, use Arrays.asList, then toArrayList making the list creation an array copy
- For the same reason, use the ArrayList(Collection) constructor
- Replace duplicate code in toList, instead calling toArrayList
Maps/Sets
- Where the size of the source is known, precalculate the capacity, using the formula used by Guava's Maps class
- For toMap where we're unable to get at the private function, use HashSet's formula where the size is known
- Add a toMap that takes a selector and a transform, avoiding a separate step for transforming values
2015-05-20 19:27:44 +03:00
Mikhail Glukhikh
633b252ff5
Unnecessary comment removed
2015-05-18 19:43:02 +03:00
Mikhail Glukhikh
fdf0ea5546
Enum warnings fixed: deprecated delimiters, short super constructors, both in project and in libraries
2015-05-18 16:08:16 +03:00
Pavel V. Talanov
5c3d8c1616
Update api usages in NoInternalVisibilityInStdLibTest
...
Broken by 01efbb1502
2015-05-18 16:01:31 +03:00
Ilya Gorbunov
f18b9caa8d
JS: Provide MIN_VALUE and MAX_VALUE member constants for Int, Long, Short and Byte companion objects.
...
JVM: Make MIN_VALUE and MAX_VALUE not an extension but member constant properties of Int, Long, Short and Byte companion objects.
2015-05-17 17:26:25 +03:00
Ilya Gorbunov
1fc5c39c22
Remove overload of joinToString with 5 parameters and it's usage from java code.
2015-05-15 03:02:48 +03:00
Ilya Gorbunov
7ffc1e13d9
Char.isLetter and Char.isLetterOrDigit (JVM).
2015-05-15 03:02:33 +03:00
Ilya Gorbunov
7721efad8a
Restore isNotEmpty and isNotBlank methods for non-nullable String receiver.
...
#KT-7234 Fixed
2015-05-15 02:59:22 +03:00
Evgeny Gerashchenko
0498bd7739
KT-7587 Overloads are not generated during partial compilation of package
...
#KT-7587 fixed
2015-05-14 21:51:08 +03:00
Sergey Mashkov
7045140d11
JS make NodeListAsList field private
2015-05-14 14:33:37 +03:00
Sergey Mashkov
f0c55c98f2
JS fix failed test caused by strings API change
2015-05-14 13:39:33 +03:00
Sergey Mashkov
0ce1edd417
JS IDL2K better callbacks support + bugfixes according to review
2015-05-14 09:16:57 +03:00