diff options
author | Paul Phillips <paulp@improving.org> | 2011-01-12 02:49:08 +0000 |
---|---|---|
committer | Paul Phillips <paulp@improving.org> | 2011-01-12 02:49:08 +0000 |
commit | 5bada810b4c7eda186aa40b94a78326520b3fa92 (patch) | |
tree | eee2227bf7f53a6b04e9732d887961b403975ab5 /src/actors | |
parent | 566fefb05abe31e90f765d1fb0a89b264302d9ce (diff) | |
download | scala-5bada810b4c7eda186aa40b94a78326520b3fa92.tar.gz scala-5bada810b4c7eda186aa40b94a78326520b3fa92.tar.bz2 scala-5bada810b4c7eda186aa40b94a78326520b3fa92.zip |
Imported sbt.Process into trunk, in the guise o...
Imported sbt.Process into trunk, in the guise of package
scala.sys.process. It is largely indistinguishable from the version in
sbt, at least from the outside.
Also, I renamed package system to sys. I wanted to do that from the
beginning and the desire has only grown since then. Sometimes a short
identifier is just critical to usability: with a function like error("")
called from hundreds of places, the difference between system.error and
sys.error is too big. sys.error and sys.exit have good vibes (at least
as good as the vibes can be for functions which error and exit.)
Note: this is just the first cut. I need to check this in to finish
fixing partest. I will be going over it with a comb and writing
documentation which will leave you enchanted, as well as removing other
bits which are now redundant or inferior. No review.
Diffstat (limited to 'src/actors')
5 files changed, 8 insertions, 8 deletions
diff --git a/src/actors/scala/actors/Actor.scala b/src/actors/scala/actors/Actor.scala index 0e52e867ca..5062bfa44c 100644 --- a/src/actors/scala/actors/Actor.scala +++ b/src/actors/scala/actors/Actor.scala @@ -543,7 +543,7 @@ trait Actor extends AbstractActor with ReplyReactor with ActorCanReply with Inpu received = Some(TIMEOUT) senders = this :: senders } else - system.error("unhandled timeout") + sys.error("unhandled timeout") } var done = false diff --git a/src/actors/scala/actors/Scheduler.scala b/src/actors/scala/actors/Scheduler.scala index d41d2ea9e8..792eae40a4 100644 --- a/src/actors/scala/actors/Scheduler.scala +++ b/src/actors/scala/actors/Scheduler.scala @@ -45,7 +45,7 @@ object Scheduler extends DelegatingScheduler { if (sched.isInstanceOf[ForkJoinScheduler]) { sched.asInstanceOf[ForkJoinScheduler].snapshot() } else - system.error("scheduler does not implement snapshot") + sys.error("scheduler does not implement snapshot") } /* Only <code>ForkJoinScheduler</code> implements this method. @@ -55,7 +55,7 @@ object Scheduler extends DelegatingScheduler { if (sched.isInstanceOf[ForkJoinScheduler]) { sched.asInstanceOf[ForkJoinScheduler].restart() } else - system.error("scheduler does not implement restart") + sys.error("scheduler does not implement restart") } } diff --git a/src/actors/scala/actors/scheduler/ForkJoinScheduler.scala b/src/actors/scala/actors/scheduler/ForkJoinScheduler.scala index c31026c3e8..ba0f88c668 100644 --- a/src/actors/scala/actors/scheduler/ForkJoinScheduler.scala +++ b/src/actors/scala/actors/scheduler/ForkJoinScheduler.scala @@ -160,9 +160,9 @@ class ForkJoinScheduler(val initCoreSize: Int, val maxSize: Int, daemon: Boolean def restart() { synchronized { if (!snapshoting) - system.error("snapshot has not been invoked") + sys.error("snapshot has not been invoked") else if (isActive) - system.error("scheduler is still active") + sys.error("scheduler is still active") else snapshoting = false diff --git a/src/actors/scala/actors/scheduler/ResizableThreadPoolScheduler.scala b/src/actors/scala/actors/scheduler/ResizableThreadPoolScheduler.scala index 575a2698e5..a317cf0a86 100644 --- a/src/actors/scala/actors/scheduler/ResizableThreadPoolScheduler.scala +++ b/src/actors/scala/actors/scheduler/ResizableThreadPoolScheduler.scala @@ -181,9 +181,9 @@ class ResizableThreadPoolScheduler(protected val terminate: Boolean, def restart() { synchronized { if (!suspending) - system.error("snapshot has not been invoked") + sys.error("snapshot has not been invoked") else if (isActive) - system.error("scheduler is still active") + sys.error("scheduler is still active") else suspending = false diff --git a/src/actors/scala/actors/threadpool/helpers/ThreadHelpers.java b/src/actors/scala/actors/threadpool/helpers/ThreadHelpers.java index 13da20c4d6..9577537f30 100644 --- a/src/actors/scala/actors/threadpool/helpers/ThreadHelpers.java +++ b/src/actors/scala/actors/threadpool/helpers/ThreadHelpers.java @@ -45,7 +45,7 @@ public class ThreadHelpers { /** * Abstraction of the exception handler which receives notifications of - * exceptions occurred possibly in various parts of the system. Exception + * exceptions occurred possibly in various parts of the sys. Exception * handlers present attractive approach to exception handling in multi-threaded * systems, as they can handle exceptions that occurred in different threads. * <p> |