diff options
author | Paul Phillips <paulp@improving.org> | 2009-06-13 14:56:58 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2009-06-13 14:56:58 +0000 |
commit | 5982a5347b342faa2c5d20ae1ec426420e2f088f (patch) | |
tree | 2b60972c0d6f13225857788b91f5738251c2a96c /docs/examples/monads/stateInterpreter.scala | |
parent | d3ff8d400fbd813015f7eeb1a886e235f9951207 (diff) | |
download | scala-5982a5347b342faa2c5d20ae1ec426420e2f088f.tar.gz scala-5982a5347b342faa2c5d20ae1ec426420e2f088f.tar.bz2 scala-5982a5347b342faa2c5d20ae1ec426420e2f088f.zip |
Fixed some deprecation warnings.
Diffstat (limited to 'docs/examples/monads/stateInterpreter.scala')
-rw-r--r-- | docs/examples/monads/stateInterpreter.scala | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/examples/monads/stateInterpreter.scala b/docs/examples/monads/stateInterpreter.scala index 499d97e418..35568fb314 100644 --- a/docs/examples/monads/stateInterpreter.scala +++ b/docs/examples/monads/stateInterpreter.scala @@ -2,7 +2,7 @@ package examples.monads; object stateInterpreter { - type State = int; + type State = Int; val tickS = new M(s => Pair((), s + 1)); @@ -25,7 +25,7 @@ object stateInterpreter { trait Term; case class Var(x: Name) extends Term; - case class Con(n: int) extends Term; + case class Con(n: Int) extends Term; case class Add(l: Term, r: Term) extends Term; case class Lam(x: Name, body: Term) extends Term; case class App(fun: Term, arg: Term) extends Term; @@ -34,7 +34,7 @@ object stateInterpreter { case object Wrong extends Value { override def toString() = "wrong" } - case class Num(n: int) extends Value { + case class Num(n: Int) extends Value { override def toString() = n.toString(); } case class Fun(f: Value => M[Value]) extends Value { |