Skip to content

Instantly share code, notes, and snippets.

@sagarpatel288
Created May 4, 2020 11:11
Show Gist options
  • Save sagarpatel288/9a1f531ce105c115ddc950731b7336f8 to your computer and use it in GitHub Desktop.
Save sagarpatel288/9a1f531ce105c115ddc950731b7336f8 to your computer and use it in GitHub Desktop.
noinline function type in an inline function
inline fun Int.doSomething(y: Int, noinline ftOne: Int.(Int) -> Int, ftTwo: (Int) -> Int) {
//passing a function type to another function
val funOne = someFunction(ftOne)
/*...*/
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment