Created
June 20, 2017 12:43
-
-
Save ezura/09c8c32be2a92be32ee8aafd5a75e415 to your computer and use it in GitHub Desktop.
呼び出し側の見た目だけ Constractor の拡張っぽいものできた
This file contains hidden or 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
| class A {} | |
| fun A(v: Int): A = A() | |
| /* | |
| A() | |
| A(1) | |
| */ |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://www.reddit.com/r/Kotlin/comments/4dtlbo/is_it_possible_to_create_extension_constructors/