Commit Graph

13904 Commits

Author SHA1 Message Date
Alexander Udalov 5e99b77de7 Compile built-ins with the new compiler in build.xml
Instead of nested "withKotlin" element in javac2 which launches
bootstrap-compiler, we launch K2JVMCompiler from the newly built compiler
directly
2014-01-27 20:36:07 +04:00
Alexander Udalov 829756dcdb Compile built-ins in ForTestCompileRuntime
Remove references to "out/production/builtins", since those built-ins are
compiled by the bootstrap compiler, whereas we want to test built-ins compiled
by the new (working copy) compiler
2014-01-27 20:36:07 +04:00
Alexander Udalov e46c54f514 Serialize built-ins on 'ant dist'
Don't store binary data in the repository anymore. From now on any test on the
compiler requires that 'ant dist' was executed at least once since the last
update of the built-ins
2014-01-27 18:33:49 +04:00
Alexander Udalov 013d226b50 Update test data after introduction of compilable built-ins
'next()' in primitive iterators is now final, as it always was in module
'runtime' before
2014-01-27 18:33:49 +04:00
Alexander Udalov 5cae5c0338 Don't fail on annotated built-ins
Unit.VALUE is annotated right now (with "suppress"), so deserialization was
throwing an exception from AnnotationDeserializer.UNSUPPORTED. Return empty
collections of annotations instead; here we use the fact that it's the only
annotation in built-ins and its presence is useless to the type checker
2014-01-27 18:33:49 +04:00
Alexander Udalov 61ad9fba4a Remove duplicated sources of built-ins
BuiltInsSerializer now serializes built-ins found in two source roots:
core/builtins/native and core/builtins/src

Add return types to some declarations in core/builtins/src, because now that
BuiltInsSerializer processes them, it launches lazy resolution which can't
always deduce the return type
2014-01-27 18:33:48 +04:00
Alexander Udalov 3b4c341046 Generate Kotlin sources of progression iterators 2014-01-27 18:33:48 +04:00
Alexander Udalov dc66561ca5 Create module 'builtins', move 'runtime' -> 'runtime.jvm'
'builtins' will be used for platform-independent core built-in definitions,
'runtime.jvm' for things that should be present at runtime in order for Kotlin
code to execute correctly on JVM

ProgressionUtil goes to 'builtins' right now because progression iterators
depend on it, but should be rewritten to Kotlin later
2014-01-27 18:33:47 +04:00
Alexander Udalov ca565b9c19 Move toString() from primitive ranges to Range
The same can't be done with progressions, because its toString() checks if an
increment is greater than zero, but Progression.increment is of type Number,
which is not Comparable<Int>
2014-01-27 18:33:47 +04:00
Alexander Udalov d88f76f438 Rewrite Progression, Range, Unit to Kotlin
Delete useless (by now) AssertInvisibleInResolver
2014-01-27 18:33:47 +04:00
Alexander Udalov d66c5b2fbe Fix floating point number hash code in ranges
Don't make 0.0 and -0.0 have the same hash code: they are different in Java (in
the sense that "Double.valueOf(0.0).equals(Double.valueOf(-0.0))" is false),
and they are considered different already in DoubleRange.equals, which calls
Double.compare, which differentiates them
2014-01-27 18:33:46 +04:00
Alexander Udalov d427fcc187 Generate Kotlin sources of progressions
The check in DoubleProgression "if (increment == 0.0 || increment == -0.0)"
(and similar in FloatProgression) was simplified to "if (increment == 0.0)"
because 0.0 == -0.0 on JVM
2014-01-27 18:33:46 +04:00
Alexander Udalov 87a6ca5910 Generate Kotlin sources of ranges 2014-01-27 18:33:46 +04:00
Alexander Udalov f9f1065294 Rewrite built-in primitive iterators to Kotlin 2014-01-27 18:33:45 +04:00
Alexander Udalov 0e7ccec9d4 Rewrite progression iterators to Kotlin 2014-01-27 18:33:45 +04:00
Alexander Udalov 1c2e1cb82f Rewrite built-in annotations to Kotlin 2014-01-27 18:33:45 +04:00
Alexander Udalov bbdc132ccd Generate FunctionN and FunctionImplN classes in Kotlin 2014-01-27 18:33:45 +04:00
Alexander Udalov a59565bfa8 Rewrite PropertyMetadata to Kotlin 2014-01-27 18:33:44 +04:00
Erokhin Stanislav bcfc67a3a6 Drop author annotations from import dart-ast source code 2014-01-27 17:29:49 +04:00
Erokhin Stanislav 93982265a6 Add js.dart-ast module & drop old lib 2014-01-27 17:28:49 +04:00
Erokhin Stanislav 3c562fc658 Imported dart-ast from https://github.com/develar/former-dast-ast to js/js.dart-ast 2014-01-27 17:28:30 +04:00
Alexander Udalov b5a75b96fa Show 'Logs' tab and extensions in run configurations
The code is copied from JUnitConfiguration, TestNGConfiguration and
ApplicationConfiguration (it's the same in those three places)
2014-01-27 17:17:44 +04:00
Zalim Bashorov bc26c66bc7 Frontend: don't resolve default parameters value when not need complete analysis. 2014-01-27 15:34:55 +04:00
Zalim Bashorov d032b5589c Frontend: fixed resolve annotation parameters on properties, accessors, accessor parameters, function parameters when not need complete analysis. 2014-01-27 15:34:55 +04:00
Zalim Bashorov f5499a93ed Added the checking of extra generation of tests in TestGenerator.
Dropped tests that have been registered more than once.
2014-01-27 15:34:54 +04:00
Christian Laakmann 9b3d357371 added extension methods MutableCollection#addAll(Iterable) and MutableCollection#addAll(Iterator) (#KT-4202 fixed) 2014-01-24 18:12:45 +04:00
Alexey Sedunov 624ac55415 Add more "Safe Delete" tests for value parameters 2014-01-24 15:24:35 +04:00
Alexey Sedunov 5f69317f1e Generate constructor light methods with origin set to Kotlin class/object declaration 2014-01-24 15:24:33 +04:00
Alexey Sedunov 001d95f4b8 Forbid safe delete action if target element is a property setter parameter 2014-01-24 15:24:32 +04:00
Alexey Sedunov 83c9c49125 Add Safe Delete tests for extension functions and properties 2014-01-24 15:24:30 +04:00
Alexey Sedunov 572e09e9ea Reuse Java safe delete for parameters in Kotlin declarations 2014-01-24 15:24:29 +04:00
Alexey Sedunov 89255b25b0 Make light parameters compatible with KotlinLightElement 2014-01-24 15:24:27 +04:00
Alexey Sedunov 1e7297015a Refactoring: Extract method 2014-01-24 15:24:26 +04:00
Alexey Sedunov c137167290 Search property declaration together with its accessor(s) 2014-01-24 15:24:24 +04:00
Alexey Sedunov bb04c5fd95 Use light element origin instead of getNavigationElement() 2014-01-24 13:10:29 +04:00
Alexey Sedunov 9eac148555 Extract base interface for Kotlin light elements 2014-01-24 13:10:28 +04:00
Alexey Sedunov f694b658ef Reuse Java safe delete for type parameters in Kotlin declarations (aside of usages in Kotlin files) 2014-01-24 13:10:27 +04:00
Alexey Sedunov 5b2858ef26 Generate light type parameters for Kotlin light methods 2014-01-24 13:10:27 +04:00
Alexey Sedunov 598a3214d2 Refactoring: Extract methods 2014-01-24 13:10:26 +04:00
Alexey Sedunov 75f67d5336 Add utility functions for conversion to light elements 2014-01-24 13:10:25 +04:00
Alexey Sedunov 2c707ec801 Reuse Java safe delete for non-local Kotlin properties 2014-01-24 13:10:24 +04:00
Alexey Sedunov b9ddf3a992 Fix warnings 2014-01-24 13:10:23 +04:00
Alexey Sedunov fffae7b6a4 Forbid "safe delete" for anonymous objects 2014-01-24 13:10:23 +04:00
Alexey Sedunov 5cfb07072c Reuse Java safe delete for Kotlin classes and objects 2014-01-24 13:10:22 +04:00
Alexey Sedunov d432c10251 Reuse Java safe delete for non-local functions in Kotlin 2014-01-24 13:10:20 +04:00
Alexey Sedunov e70af5d372 Improvements in element description provider (proper treatment of light classes/methods, support of simple vs qualified names) 2014-01-24 13:10:19 +04:00
Alexey Sedunov fc848ec263 Translate "Safe Delete" usage info classes to Kotlin 2014-01-24 13:10:18 +04:00
Alexander Udalov c1777f28f9 Fix NPE in annotation deserializer 2014-01-23 22:02:59 +04:00
Valentin Kipyatkov 3e4b0d960a Added missing intention description 2014-01-23 20:27:36 +04:00
Valentin Kipyatkov 020ea99220 Intention "Convert to expression body" 2014-01-23 18:50:26 +04:00