Alexey Andreev
acf7fcaebf
JS: prohibit is checks against native interfaces. Warn about casts to native interfaces. Fix #KT-14037, fix #KT-14038
2016-11-25 14:07:29 +03:00
Alexey Andreev
ea1e196e9a
JS: remove unused imports from generated JS. Fix KT-14748
2016-11-23 12:19:04 +03:00
Alexey Andreev
cf89e24b49
JS: fix removal of unused lambdas after inlining
2016-11-23 12:19:04 +03:00
Alexey Andreev
8b9852edec
JS: remove Kotlin.createClass/definePackage/etc functions from stdlib. Reimplement some classes in Kotlin
2016-11-23 12:13:54 +03:00
Alexey Andreev
85a775375a
JS: when deciding whether inner class of a local class captures this, don't check for subtyping, since frontend generates strict classes in descriptors. Remove fix for #KT-13583, since it's no more needed. Fix #KT-13792
2016-11-21 12:57:59 +03:00
Dmitry Petrov
4c47d77a9f
Report error on non-top-level type aliases (unsupported in 1.1).
...
Get rid of nested type aliases in project.
2016-11-21 10:25:51 +03:00
Zalim Bashorov
ef11393462
KJS: add multimodule version of inheritFromRenamedNativeClass
2016-11-17 16:22:31 +03:00
Zalim Bashorov
8c630954a8
Minor: fix typo in file name
2016-11-17 16:22:30 +03:00
Zalim Bashorov
e1248f8f0b
KJS: don't copy members from native interfaces
2016-11-17 16:22:29 +03:00
Zalim Bashorov
01d10a9592
KJS: remove no longer valid test
2016-11-17 16:22:28 +03:00
Zalim Bashorov
aa2a4f0794
KJS: implement Throwable in Kotlin instead of use it as alias of JS Error
...
* Make it an inheritor of JS Error. Otherwise, Chakra engine doesn't fill stack trace of exception; In other engines inheritance has some good effects too.
* Copy all properties from internally created instance of JS Error
#KT-6985 Fixed
#KT-2328 Fixed
#KT-8019 Fixed
#KT-10911 Fixed
2016-11-17 16:22:27 +03:00
Zalim Bashorov
a03e22e774
KJS: fix refering to native nested class
2016-11-17 16:21:16 +03:00
Zalim Bashorov
bd90b4e051
KJS: don't overwrite prototype of native classes when inheriting from them
2016-11-17 16:17:44 +03:00
Zalim Bashorov
c25dfe997c
KJS: fix inheritance from renamed native classes
2016-11-17 16:17:43 +03:00
Anton Bannykh
0dc9121a91
JS property accessors inlining (KT-13456)
2016-11-17 15:25:29 +03:00
Ilya Gorbunov
4769ed5f79
Fix imports in tests: do not use java.util.* stuff
2016-11-16 18:47:42 +03:00
Alexey Andreev
5ef8879aae
JS: fixes after code review
2016-11-11 16:26:39 +03:00
Alexey Andreev
a72ea64142
JS: fix translation of lambdas in public inline functions; fix AMD emulation for Ant test
2016-11-11 16:26:39 +03:00
Alexey Andreev
6791ed7bf3
JS: fix obsolete tests
2016-11-11 16:26:38 +03:00
Alexey Andreev
ac4bfc645e
JS: refactor translation of callable references to top-level properties
2016-11-11 16:26:38 +03:00
Alexey Andreev
0252fe57af
JS: refactor flat declaration generator. Add more tests on inter-module dependencies
2016-11-11 16:26:37 +03:00
Alexey Andreev
3d9beb15da
JS: fix translation of !! operation
2016-11-11 16:26:36 +03:00
Alexey Andreev
cacd917350
JS: fix translation of extension properties
2016-11-11 16:26:36 +03:00
Alexey Andreev
0f87703c87
JS: rewrite code that copies interface members with implementation to subtypes
2016-11-11 16:26:35 +03:00
Alexey Andreev
bb57eaef96
JS: fix some minor issues in new flat translator
2016-11-11 16:26:34 +03:00
Alexey Andreev
20396b0e5f
JS: fix inlining in a new flat JS generator
2016-11-11 16:26:32 +03:00
Alexey Andreev
f9a392fdec
JS: introduce new flat JS declaration structure
2016-11-11 16:26:31 +03:00
Zalim Bashorov
5f2ba70745
KJS: use cached KClass instead create new each time when getting it from JsClass
2016-10-18 13:26:05 +03:00
Zalim Bashorov
a085df914f
KJS: allow to use KClass::isInstance; implement isInstance in KClassImpl
2016-10-18 13:26:05 +03:00
Zalim Bashorov
11b2c5fe59
JS: change visibility to internal for library and marker annotations
2016-10-14 19:44:57 +03:00
Zalim Bashorov
3c520a3ce3
JS backend: basic support for class literals.
...
Added:
* the ability to get KClass using class literals (`::class`);
* the ability to get KClass from JsClass and vice versa;
* the ability to get simpleName.
#KT-13345 Fixed
2016-10-14 19:44:53 +03:00
Zalim Bashorov
ace10f46b2
Minor: move reflection/light/* -> reflection/*
2016-10-14 19:40:36 +03:00
Zalim Bashorov
d31f18137d
JS: make Any as upper bound of type parameter of JsClass and helpers
2016-10-14 19:40:35 +03:00
Alexey Andreev
30c2c85c94
KT-13830: support case when LHS of augmented assignment is something different than qualified expression or array access
2016-10-11 11:54:04 +03:00
Alexey Andreev
61b429f2f0
JS: fix exception during translation of for expression with iterator having generic type constrained by Iterable. Fix #KT-8385
2016-10-10 11:22:21 +03:00
Alexey Andreev
322f6fe7ac
KT-2752: fix translation of call to internal function from subclass
2016-10-08 19:25:53 +03:00
Alexey Andreev
831ac97ecd
KT-2752: fix some tests and make them slightly less fragile
2016-10-08 19:25:51 +03:00
Alexey Andreev
9c7c82b151
KT-2752: refactor NameSuggestion, change rules for determining name stability and applying mangling
2016-10-08 19:25:50 +03:00
Alexey Andreev
6f7e7d8504
KT-2752: fixes after code review
2016-10-08 19:25:49 +03:00
Alexey Andreev
ba9c908875
KT-2752: export JsName on class via JS reflection
2016-10-08 19:25:45 +03:00
Alexey Andreev
aa5d15cff7
KT-2752: minor fixes after code review
2016-10-08 19:25:43 +03:00
Alexey Andreev
7956b038fd
KT-2752: add test to prove that KT-13024 is no longer reproducible with new implementation of name mangling
2016-10-08 19:25:43 +03:00
Alexey Andreev
fb7f221158
KT-2752: add test to ensure that JsName affects classes
2016-10-08 19:25:40 +03:00
Alexey Andreev
33daf83f14
KT-2752: refactoring:
...
1. Get rid of most of ManglingUtils
2. Use simple mangling for delegated properties instead of stable mangling
3. Use stable mangling for public declarations of open non-public classes
4. When generating a fresh name in a JsScope, check it for clashing against parent scopes
5. JsFunctionScope does not generate fresh name instead of stable names
6. Function scopes inherit directly from global scope
7. Generate simple mangled names for backing fields of properties
2016-10-08 19:25:36 +03:00
Alexey Andreev
725d13b72e
KT-2752: fix JsName with explicit use target. Add some tests for JsName with use targets
2016-10-08 19:25:33 +03:00
Alexey Andreev
6e1a0901ac
KT-2752: add checkers for inconsistent usage of JsName
2016-10-08 19:25:31 +03:00
Alexey Andreev
5ce158f297
KT-2752: add basic tests for JsName
2016-10-08 19:25:28 +03:00
Alexey Andreev
5e3aa33b13
KT-2752: add draft implementation of JsName annotation. Fix some tests using the annotation
2016-10-08 19:25:27 +03:00
Alexey Andreev
f70b50b6e2
KT-2752: refactor generation of FQN in JS. Move backend-independent code to generic code in frontend.
2016-10-08 19:25:25 +03:00
Ilya Gorbunov
2aa60adbca
Remove 'import java.util' from js tests.
2016-10-03 17:25:26 +03:00