Sign in
pigweed
/
third_party
/
github
/
JetBrains
/
kotlin
/
9fc4d94d04f972782fee2dc5b3b25d052d88601a
/
.
/
compiler
/
testData
/
diagnostics
/
tests
/
safeCalls
/
safeCallWithSmartCast.kt
blob: f891067df77bdc721563f63c216d3151c30d4765 [
file
]
// WITH_STDLIB
class
C
{
var
x
:
Int
=
0
}
fun test
(с:
C
?,
a
:
Any
)
{
с?.
x
=
if
(
a
is
String
)
0
else
throw
Exception
();
<!
DEBUG_INFO_SMARTCAST
!>
a
<!>.<!
DEPRECATION
!>
toUpperCase
<!>()
}
fun main
(
args
:
Array
<
String
>)
{
test
(
null
,
1
)
}