Created
January 10, 2022 09:23
-
-
Save whytrall/6c5904d00c3c4d090bee2b2dcefee8d0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import RickRoll.writer | |
object RickRoll { var writer: (String) -> Unit = { println(it) } } | |
val Never = RickAstleyNever // to get different highlighting color | |
object RickAstleyNever { | |
infix fun gonna(x: give) = give | |
infix fun gonna(x: let) = let | |
infix fun gonna(x: run) = run | |
infix fun gonna(x: make) = make | |
infix fun gonna(x: say) = say | |
infix fun gonna(x: tell) = tell | |
} | |
object give { infix fun you(x: up) = Unit } | |
object let { infix fun you(x: down) = Unit } | |
object make { infix fun you(x: cry) = Unit } | |
object say { infix fun goodbye(x: RickAstleyNever) = Never.apply { writer("Never gonna say goodbye") } } | |
object tell { infix fun a(x: lie) = lie } | |
object lie { infix fun and(x: hurt) = hurt } | |
object hurt { infix fun you(x: YouHaveBeenRickRolled) { writer("Never gonna tell a lie and hurt you") } } | |
object cry { init { writer("Never gonna make you cry") } } | |
object up { init { writer("Never gonna give you up") } } | |
object down { init { writer("Never gonna let you down") } } | |
object run { infix fun around(x: and) = and } | |
object you { init { writer("Never gonna run around and desert you") } } | |
object and { infix fun desert(x: you) {} } | |
object YouHaveBeenRickRolled | |
val dQw4w9WgXcQ = YouHaveBeenRickRolled |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
❤️