Commit Graph

3322 Commits

Author SHA1 Message Date
Alexander Udalov 05f8836f46 Move some configuration keys to JVM or to CommonConfigurationKeys
Move CONTENT_ROOTS and SCRIPT_DEFINITIONS_KEY to JVMConfigurationKeys because
they are only used on JVM, rename the latter to SCRIPT_DEFINITIONS.

Move MODULE_NAME to CommonConfigurationKeys to be combined with MODULE_ID in
JSConfigurationKeys in the future
2016-05-26 11:47:30 +03:00
Alexander Udalov b65980f3b7 Drop JsConfig#inlineEnabled flag
Use CommonConfigurationKeys#DISABLE_INLINE flag (moved from
JVMConfigurationKeys) in CompilerConfiguration instead, similarly to the JVM
compiler
2016-05-26 11:47:30 +03:00
Alexander Udalov 8c0f78db50 Introduce CompilerConfiguration#getNotNull and getBoolean
To reduce boilerplate at call sites
2016-05-26 11:47:30 +03:00
Alexander Udalov cf19166eca Move IC-related initialization logic to GenerationState
To further reduce number of parameters of GenerationState's constructor
2016-05-23 14:50:06 +03:00
Alexander Udalov 29c5e655ab Drop several more parameters of GenerationState's constructor
INCREMENTAL_COMPILATION_COMPONENTS and DECLARATIONS_JSON_PATH are already in
the configuration, and Progress was unused
2016-05-23 14:50:06 +03:00
Alexander Udalov f8816b5d67 Pass CompilerConfiguration to GenerationState instead of ton of parameters 2016-05-23 14:49:26 +03:00
Alexander Udalov 1b79770121 Do not produce trailing space when rendering root package header 2016-05-20 14:53:07 +03:00
Dmitry Petrov 65293008fd KT-11588 Type aliases
Type alias descriptor serialization
Types with type aliases serialization
2016-05-20 14:17:24 +03:00
Mikhail Glukhikh ebd57fafd7 Cleanup: val can be parameter 2016-05-20 13:38:42 +03:00
Stanislav Erokhin 74bddcfb70 Refactoring. Convert Annotated to kotlin. 2016-05-20 09:32:55 +03:00
Alexander Udalov 2200bfcc85 Simplify ImplementationBodyCodegen#generateToArray
- don't do anything for interfaces because there's no point in generating
  abstract methods which are already abstract in supertypes
- don't use getDeclaredFunctionByRawSignature, check function signature
  manually instead
- don't use isOrOverridesSynthesized because 'toArray' is never synthesized
2016-05-20 00:54:18 +03:00
Alexander Udalov c1c2651988 J2K backend-common classes: convert
Also merge CodegenUtilKt into CodegenUtil
2016-05-20 00:36:56 +03:00
Stanislav Erokhin 7332032bb6 Support sealed class inheritors in the same file
#KT-11573 Fixed
2016-05-19 16:22:40 +03:00
Mikhail Glukhikh f35fd32a25 Exhaustive when with 'Unit' result now also generates an exception in else branch #KT-12192 Fixed 2016-05-17 14:28:57 +03:00
Mikhael Bogdanov 48c8678281 Extracted logic of obtaining delegated local variable metadata 2016-05-13 19:11:24 +03:00
Mikhael Bogdanov c06b51c1d1 Allow top-level local delegated properties in scripts 2016-05-13 19:11:23 +03:00
Mikhael Bogdanov 5e933b7acd localVariableReferences.kt moved from reflection.jvm to runtime.jvm 2016-05-13 19:11:22 +03:00
Mikhael Bogdanov ec632c37ab Support increment and '+=' on local delegated properties 2016-05-13 19:11:21 +03:00
Mikhael Bogdanov 6ae511b253 LocalVariableDescriptor.withAccessors renamed to isDelegated, added getter 2016-05-13 19:11:20 +03:00
Dotlin 4c223845b6 Delegated Properties: Code generation for local properties (JVM) 2016-05-13 19:11:19 +03:00
Mikhail Glukhikh 733f3e8025 Code cleanup: type parameters can have in / out variance 2016-05-13 17:57:02 +03:00
Alexey Tsvetkov 6f3ea01084 Refactoring: rename ClassBuilderMode entry LIGHT_CLASSES_WITH_METADATA->KAPT 2016-05-11 20:41:48 +03:00
Alexey Tsvetkov 10b9be9f51 Fix collecting source retention annotations
#KT-12187 fixed
2016-05-11 20:41:48 +03:00
Alexey Tsvetkov f2ca788ea3 Serialize error type to proto when generating stubs 2016-05-11 20:41:48 +03:00
Alexey Tsvetkov 4b591d2220 Include metadata in light classes for kapt 2016-05-11 20:41:48 +03:00
Mikhael Bogdanov d6a64af929 Fix for KT-12125: Wrong increment/decrement on Byte/Char/Short.MAX_VALUE/MIN_VALUE
#KT-12125 Fixed
2016-05-11 18:07:25 +03:00
Mikhael Bogdanov ee7bbbf530 Fix for KT-12127: Undeclared type variable on delegated property backing field
#KT-12127 Fixed
2016-05-04 17:07:48 +03:00
Denis Zharkov d259b91143 Add MutableMap.remove(K, V) as built-in declaration
Use PlatformDependent annotation to guarantee it's only be available for JDK8
Also adjust type-safe bridges and mutable collection stubs generation
2016-04-29 15:08:54 +03:00
Valentin Kipyatkov b551886889 Code cleanup: removed redundant semicolons 2016-04-29 11:26:25 +03:00
Kirill Rakhman 4a619db721 Add intrinsic for KCallable.name property Fixes #KT-11531 2016-04-28 23:03:00 +03:00
Mikhail Glukhikh 5a66ef2126 Core & compiler: unnecessary 'val's removed from constructors 2016-04-27 18:41:56 +03:00
Stanislav Erokhin c6cb5175a4 Minor. Use capability instead of capabilities. 2016-04-27 14:13:59 +03:00
Denis Zharkov 1efed64014 Use JVM signatures instead of FQ-names for additional built-ins 2016-04-25 17:41:08 +03:00
Denis Zharkov 8cf29ea4f3 Extract JVM descriptors type mapping from backend to core
Also unbind it from ASM types
2016-04-25 17:41:08 +03:00
Denis Zharkov 7fe5a9db8d Remove JavaToKotlinClassMap dependency on built-ins instance 2016-04-25 17:41:08 +03:00
Denis Zharkov 5bf39689e9 Replace irrelevant usages of JvmBuiltIns.Instance with DefaultBuiltIns.Instance 2016-04-25 17:41:08 +03:00
Denis Zharkov c667f50741 Delete TargetPlatform.builtins
Replace it's usages with relevant singleton reference
2016-04-25 17:41:08 +03:00
Denis Zharkov ef18d64931 Parametrize module creation by platform with built-ins 2016-04-25 17:41:08 +03:00
Dmitry Petrov f3c006a5f5 RedundantCoercionToUnitTransformer: do not create individual objects for each transformation. 2016-04-22 17:38:44 +03:00
Michael Bogdanov 7335f2394b Sort result ranges in SMAP class 2016-04-21 17:32:03 +03:00
Michael Bogdanov d945c47b63 Skip line numbers that couldn't be mapped by SourceMappers 2016-04-21 17:32:03 +03:00
Michael Bogdanov 9a8474392d Code clean 2016-04-20 17:07:17 +03:00
Michael Bogdanov 2cec779c14 'visitLineNumber' replaced with 'mapLineNumber' in SourceMapper 2016-04-20 17:07:16 +03:00
Michael Bogdanov c70e1c6065 SourceMappers refactoring 2016-04-20 17:07:15 +03:00
Michael Bogdanov bb5c24eae5 Old SourceMappers replaced with new ones 2016-04-20 17:07:15 +03:00
Michael Bogdanov af68f3d019 Added additional strata for stacktraces 2016-04-20 17:07:12 +03:00
Michael Bogdanov f6edf311d7 Optimization in NestedSourceMapper 2016-04-20 17:07:11 +03:00
Michael Bogdanov 636c13adde Small optimization in InlineLambdaSourceMapper 2016-04-20 17:07:11 +03:00
Michael Bogdanov ab2d3665a4 SourceMapper api refactoring 2016-04-20 17:07:08 +03:00
Michael Bogdanov 225e90bbdf Removed redundant cache, small rename refactoring after removing 2016-04-20 17:07:08 +03:00