Files
kotlin-fork/libraries/stdlib/common/test/testUtils.kt
T
Nikita Bobko 9a865e4c55 [FE 1.0] Issue a warning if expect and actual are declared in the same module
The commit is based on b09561c3c3
Co-authored-by: Dmitriy Novozhilov <dmitriy.novozhilov@jetbrains.com>

^KT-40904 Fixed
^KT-55177 Fixed
Review: https://jetbrains.team/p/kt/reviews/8731

True negative test already exist:
`compiler/testData/diagnostics/tests/multiplatform/hmpp/multiplatformCompositeAnalysis/intermediateWithActualAndExpect.kt`
2023-02-21 14:45:46 +01:00

38 lines
1.1 KiB
Kotlin

/*
* Copyright 2010-2020 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
@file:Suppress("EXPECT_AND_ACTUAL_IN_THE_SAME_MODULE")
package test
public expect fun assertTypeEquals(expected: Any?, actual: Any?)
public expect fun testOnJvm(action: () -> Unit)
public expect fun testOnJs(action: () -> Unit)
public expect val isFloat32RangeEnforced: Boolean
public expect val supportsNamedCapturingGroup: Boolean
public expect val supportsOctalLiteralInRegex: Boolean
public expect val supportsEscapeAnyCharInRegex: Boolean
public expect val regexSplitUnicodeCodePointHandling: Boolean
public enum class HandlingOption {
MATCH_NOTHING, THROW, IGNORE_BACK_REFERENCE_EXPRESSION
}
public expect object BackReferenceHandling {
val captureLargestValidIndex: Boolean
val notYetDefinedGroup: HandlingOption
val notYetDefinedNamedGroup: HandlingOption
val enclosingGroup: HandlingOption
val nonExistentGroup: HandlingOption
val nonExistentNamedGroup: HandlingOption
val groupZero: HandlingOption
}