Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- case class Literal(message: String) extends AnyVal
- object test {
- val single = new Literal("Coffee")
- def load = Map[String, Literal](
- ("playWithAFriend", Literal("""Jouer avec un(e) ami(e)""")),
- ("playWithTheMachine", Literal("""Jouer contre l'ordinateur""")))
- }
- /*
- * Compiles to:
- *
- object test extends Object {
- private[this] val single: String = _;
- <stable> <accessor> def single(): String = test.this.single;
- def load(): scala.collection.immutable.Map = scala.Predef.Map().apply(scala.Predef.wrapRefArray(Array[Tuple2]{new Tuple2("playWithAFriend", new Literal("Jouer avec un(e) ami(e)")), new Tuple2("playWithTheMachine", new Literal("Jouer contre l\'ordinateur"))}.$asInstanceOf[Array[Object]]())).$asInstanceOf[scala.collection.immutable.Map]();
- def <init>(): test.type = {
- test.super.<init>();
- test.this.single = "Coffee";
- ()
- }
- }
- */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement