Yentl Van Tendeloo 7 лет назад
Родитель
Сommit
98b505e19a
2 измененных файлов с 7 добавлено и 11 удалено
  1. 6 10
      kernel/modelverse_kernel/request_handler.py
  2. 1 1
      wrappers/modelverse_SCCD.py

+ 6 - 10
kernel/modelverse_kernel/request_handler.py

@@ -22,16 +22,12 @@ class RequestHandler(object):
 
                 # Generated new request, so process
                 if requests and requests[0][0] in self.handlers:
-                        # Known request, so process that one
-                        if len(requests) > 1:
-                            raise Exception("CALL_* and SLEEP operations MUST be split in individual yields")
-
-                        # Try to add a new generator to branch into
-                        reply = None
-                        self.generator_stack.append(None)
-                        # This next command potentially raises a finished message already, meaning that we should stop already
-                        # We avoid an extra try/except block by putting the None on the stack already
-                        self.generator_stack[-1] = self.handlers[requests[0][0]](requests[0][1])
+                    # Try to add a new generator to branch into
+                    reply = None
+                    self.generator_stack.append(None)
+                    # This next command potentially raises a finished message already, meaning that we should stop already
+                    # We avoid an extra try/except block by putting the None on the stack already
+                    self.generator_stack[-1] = self.handlers[requests[0][0]](requests[0][1])
                 else:
                     # MvS request, so forward that instead
                     return requests

+ 1 - 1
wrappers/modelverse_SCCD.py

@@ -1,7 +1,7 @@
 """
 Generated by Statechart compiler by Glenn De Jonghe, Joeri Exelmans, Simon Van Mierlo, and Yentl Van Tendeloo (for the inspiration)
 
-Date:   Fri Apr 27 13:39:47 2018
+Date:   Fri Apr 27 13:51:23 2018
 
 Model author: Yentl Van Tendeloo
 Model name:   MvK Server