Check lambda parameter for name shadowing

#KT-5160 Fixed
This commit is contained in:
Mikhail Zarechenskiy
2017-04-17 10:40:41 +03:00
parent 708bfdbd5f
commit 32f609ceee
15 changed files with 61 additions and 19 deletions
@@ -22,6 +22,6 @@ fun bar(b: B): String {
// Ok: local variable
val tmp = if (b is A && b is C) b else null
// Error: local function
fun <!IMPLICIT_INTERSECTION_TYPE!>foo<!>(b: B) = if (b is A && b is C) b else null
fun <!IMPLICIT_INTERSECTION_TYPE!>foo<!>(<!NAME_SHADOWING!>b<!>: B) = if (b is A && b is C) b else null
return tmp.toString()
}