Commit Graph

21240 Commits

Author SHA1 Message Date
Ilya Gorbunov 25cfd36e7c drop, take: combine implementations for Collections, Lists and Iterables.
slice: predict length of resulting list.
2015-03-25 03:26:18 +03:00
Ilya Gorbunov 4a7918b0a1 Add takeLast method for String, lists and arrays.
Check the parameter n in drop, take and takeLast methods.
2015-03-25 03:26:06 +03:00
Ilya Gorbunov 05b5afcb94 Add removePrefix, removeSuffix, removeEnclosing methods.
Deprecate trimLeading/trimTrailing/trim(String) methods in favor of new ones.
2015-03-25 03:25:53 +03:00
Ilya Gorbunov 0484d3bf2f Imperative trim implementation to prevent double lambda expansion in inline function. 2015-03-25 03:25:40 +03:00
Ilya Gorbunov 5b2a5c78ca Fix js-stdlib compilation and tests. 2015-03-25 03:25:27 +03:00
Ilya Gorbunov 4c58f4ec20 Add removeRange method.
Breaking change in replaceRange(IntRange, String) method: the end index of the range now is included in the part being replaced.
2015-03-25 03:25:14 +03:00
Ilya Gorbunov ba15e5b295 Trimming and padding methods.
Kinda breaking change: Char.isWhitespace treats non-breaking spaces as whitespace too to match the Unicode definition of whitespace.
2015-03-25 03:25:01 +03:00
Ilya Gorbunov 0580039ded Provide additional string conversion methods to match missing java.lang.String constructors.
Fixes KT-5019
2015-03-25 03:24:48 +03:00
Dmitry Jemerov 843298883f shuffle some code around to avoid JVM crash in tests 2015-03-24 19:08:41 +01:00
Dmitry Jemerov 20fbb814e4 remove abstraction which is no longer needed 2015-03-24 20:21:23 +03:00
Dmitry Jemerov d2634eb7eb remove obsolete module script generator from JPS 2015-03-24 20:21:22 +03:00
Mikhail Glukhikh 2bc124fa3d IO second review: empty File.subPath() allowed, OutputStream.bufferedWriter() added,
normalize(), startsWith(), endsWith() rewritten, LinesStream --> LinesSequence,
File.replaceBytes() / replaceText() rolled back to writeBytes() / writeText(),
some exception messages formulated more clearly, refactorings, comments,
relativeTo() slightly optimized, additional tests
2015-03-24 19:52:19 +03:00
Mikhail Glukhikh 88733d34eb Additional fix of String.getRootName() for network names, relevant test fixes 2015-03-24 19:40:24 +03:00
Mikhail Glukhikh 5b636eef7b Kotlin I/O review/M11 fixes: Stream --> Sequence, recurse() returned back,
additional helpers like File.bufferedReader() and String.byteInputStream(),
copyRecursively / deleteRecursively were rewritten using FileTreeWalk,
FilePathComponents introduced as a replacement of FileIterator,
classes / methods / properties permissions fixed, Linux specific things,
resolveSibling rewritten using FilePathComponents
2015-03-24 19:40:21 +03:00
Denis Mekhanikov f560677b15 Kotlin I/O new features: relativeTo, copyTo, copyRecursively, deleteRecursively, file tree walkers,
file component iterators, file roots, startsWith, endsWith, subPath, normalize, replaceBytes, replaceTest,
additional tests and comments
2015-03-24 19:40:19 +03:00
Michael Nedzelsky dae42f7c76 fix EA-66819 - IOE: VirtualDirectoryImpl.contentsToByteArray
Changes: do not try to read content for virtual file in case it is really a directory
2015-03-24 18:58:42 +03:00
Dmitry Jemerov 5370073c05 parameters in KDoc take precedence over other identifiers 2015-03-24 16:05:40 +01:00
Yan Zhulanow 900c67de4e Replicate idea-version from the main plugin.xml to the android-idea-plugin plugin.xml 2015-03-24 16:43:45 +03:00
Alexey Sedunov 3e429c4b00 Change Signature: Fix behavior of "Receiver" checkbox 2015-03-24 16:41:10 +03:00
Alexey Sedunov 461ae25239 Find Usages: Properly select primary element for Find Usages Dialog. Avoid delegating handler when there is only one primary element
#KT-7048 Fixed
2015-03-24 16:41:09 +03:00
Alexey Sedunov a57be6dcab Change Signature: Do not report conflict when parameter name clashes with suggested name of the receiver 2015-03-24 16:41:08 +03:00
Alexey Sedunov 0eda6c88b9 Quick-Fixes: Fix signature configuration for extension functions
#KT-7019 Fixed
2015-03-24 16:41:07 +03:00
Alexey Sedunov 93f00db871 Extraction Engine: Consider declarations when comparing descriptors
#KT-6960 Fixed
2015-03-24 16:41:05 +03:00
Alexey Sedunov 502b67ecc0 Extract Function: Support multi-file tests 2015-03-24 16:41:04 +03:00
Alexey Sedunov 16a4dbd692 Quick-Fixes: Do not add 'abstract' modifier to anonymous objects
#KT-6656 Fixed
2015-03-24 16:41:03 +03:00
Alexey Sedunov 1ed2c82008 Quick-Fixes: Approximate non-denotable type with nearest denotable supertype
#KT-5915 Fixed
2015-03-24 16:41:01 +03:00
Alexey Sedunov a2162810ff Quick-Fixes: Drop unnecessary parentheses when simplifying cast expressions
#KT-6501 Fixed
2015-03-24 16:40:59 +03:00
Alexey Sedunov 71a5e09a0b Quick-Fixes: Support USELESS_CAST diagnostic in "Remove cast" quick-fix
#KT-6422 Fixed
2015-03-24 16:40:58 +03:00
Alexey Sedunov f5107be315 Quick-Fixes: Support "Change function return type" quick-fix for non-local returns
#KT-6910 Fixed
2015-03-24 16:40:57 +03:00
Michael Nedzelsky 842eaa86a4 merge serialization.js module into js.serializer 2015-03-24 15:13:45 +03:00
Dmitry Jemerov e550dba033 Merge remote-tracking branch 'origin/master' 2015-03-23 19:00:33 +01:00
Dmitry Jemerov 06ac8b89b8 Merge branch 'rr/yole/module-md-rewrite' 2015-03-23 19:00:17 +01:00
Dmitry Jemerov bd1a116c9e add documentation for recently added packages 2015-03-23 18:52:27 +01:00
Alexander Udalov 0fe0235525 Improve built-in initialization error message 2015-03-23 17:15:06 +03:00
Dmitry Jemerov 408f7da0c5 correct indentation after pressing Enter in KDoc tag
#KT-7044 Fixed
2015-03-23 15:06:59 +01:00
Alexey Tsvetkov 03f0c6ede7 JS: added test for callable reference as stdlib inline function argument 2015-03-23 16:43:49 +03:00
Alexey Tsvetkov 1557111277 JS: fix issues with js() usage in inline functions 2015-03-23 16:43:49 +03:00
Alexey Tsvetkov 5ff5cea17a JS: report error when js() produces empty AST 2015-03-23 16:43:49 +03:00
Alexey Tsvetkov eb4f6b8a1e JS: generate shorter tag for inline functions 2015-03-23 16:43:49 +03:00
Alexey Tsvetkov 8be3628074 JS: removed comma expression decomposition from InlineMetadata
There are used to be two inline tags (corresponding to start, end of inline function).
An expression like "startTag, function, endTag" was parsed into comma expression, then decomposed.
Now, it's just one tag at start, and parser can read function, then stop.
Thus, there is no need to decompose comma expressions.
2015-03-23 16:43:48 +03:00
Alexey Tsvetkov c7e8f52faf JS: use one tag for inlining 2015-03-23 16:43:48 +03:00
Alexey Tsvetkov e83b253b3e JS: renamed JsParser->JsAstMapper 2015-03-23 16:43:48 +03:00
Alexey Tsvetkov b5797eb15b JS: added tests for recursion cycle in inline functions 2015-03-23 16:43:48 +03:00
Alexey Tsvetkov 24f2121f9b JS: report error from backend, when inline function is called recursively 2015-03-23 16:43:48 +03:00
Alexander Udalov 7e69a5ac9a Don't create KProperty instance for synthetic field
#KT-5759 Fixed
2015-03-23 16:30:26 +03:00
Alexander Udalov a5a60b6917 Move code from file named util.kt to meaningful place 2015-03-23 16:30:25 +03:00
Alexander Udalov 9a041136f2 Make ClassId's relative class name FqName instead of FqNameUnsafe
It was FqNameUnsafe in times when there were classes without identifier names,
specifically class objects with names like '<class-object-for-...>'
2015-03-23 16:30:25 +03:00
Alexander Udalov 31554b9fa3 Introduce ClassId.getShortClassName() for convenience 2015-03-23 16:30:24 +03:00
Alexander Udalov 9cf0720925 Fix KClass.simpleName for local classes 2015-03-23 16:30:24 +03:00
Alexander Udalov aaef2d42cd Do not report "no reflection" inspection in JS modules
#KT-7087 Fixed
2015-03-23 15:54:34 +03:00