41299287cf
The correct return type of getAnnotatedBounds is Array<AnnotatedType>.
This fact causes some problems now that kotlin-stdlib is targeting JDK
1.8:
* the compiler generates a bridge to the incorrect "override" that
attempts to cast an empty Array<Annotation> into the correct type,
which fails because those two types are unrelated;
* on Android, touching this method in any way (via reflection) on
any API version causes a ClassNotFoundException;
* tools that validate references in libraries when compiling for
Android complain about the bridge because they know the returned
type does not exist.
The easiest solution is to simply remove the override and leave
getAnnotatedBounds unimplemented, making it throw AbstractMethodError
when called. This is the behavior it previously had anyway, as
kotlin-stdlib targeting JDK 1.6 lacked a method with the correct
signature.
The Kotlin Standard Library
This module creates the standard library for Kotlin.
Notes for contributors
We use code generation to generate utility extension functions for some collection-like types like arrays, strings, Collection<T>, Sequence<T>, Map<K, V> etc.
These sources are placed into the generated folder and their names are prefixed with an underscore, for example, generated/_Collections.kt
To run the code generator, use the following command in the root directory of the project:
./gradlew :tools:kotlin-stdlib-gen:run
Note: on Windows type
gradlewwithout the leading./
This then runs the script which generates a significant part of stdlib sources from the templates written in a special Kotlin-based DSL.
Usage samples
If you want to author samples for the standard library, please head to the samples readme.