summaryrefslogtreecommitdiff
path: root/odcsim
diff options
context:
space:
mode:
Diffstat (limited to 'odcsim')
-rw-r--r--odcsim/odcsim-engine-omega/src/main/kotlin/com/atlarge/odcsim/engine/omega/OmegaSimulationEngine.kt1
1 files changed, 1 insertions, 0 deletions
diff --git a/odcsim/odcsim-engine-omega/src/main/kotlin/com/atlarge/odcsim/engine/omega/OmegaSimulationEngine.kt b/odcsim/odcsim-engine-omega/src/main/kotlin/com/atlarge/odcsim/engine/omega/OmegaSimulationEngine.kt
index 0133832c..e675b877 100644
--- a/odcsim/odcsim-engine-omega/src/main/kotlin/com/atlarge/odcsim/engine/omega/OmegaSimulationEngine.kt
+++ b/odcsim/odcsim-engine-omega/src/main/kotlin/com/atlarge/odcsim/engine/omega/OmegaSimulationEngine.kt
@@ -126,6 +126,7 @@ public class OmegaSimulationEngine(override val name: String) : SimulationEngine
* Schedule the specified event to be processed by the engine.
*/
private fun schedule(@Async.Schedule event: Event) {
+ assert(event.time >= clock.time) { "Message scheduled in the past [received=${event.time}, actual=${clock.time}]" }
queue.add(event)
}