Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- case class User(name: String, id: Long = 0L)
- object User {
- def apply(name: String, id: Long): User =
- User(name, (id == 0L) ? <some random number> : id)
- }
- ambiguous reference to overloaded definition
- ...
- method apply is defined twice
Add Comment
Please, Sign In to add comment