equal
deleted
inserted
replaced
194 } |
194 } |
195 |
195 |
196 private def invoke_scala(msg: Prover.Protocol_Output): Boolean = synchronized |
196 private def invoke_scala(msg: Prover.Protocol_Output): Boolean = synchronized |
197 { |
197 { |
198 msg.properties match { |
198 msg.properties match { |
199 case Markup.Invoke_Scala(name, id) => |
199 case Markup.Invoke_Scala(name, id, thread) => |
200 futures += (id -> |
200 def body |
201 Future.fork { |
201 { |
202 val (tag, res) = Scala.function(name, msg.text) |
202 val (tag, res) = Scala.function(name, msg.text) |
203 result(id, tag, res) |
203 result(id, tag, res) |
204 }) |
204 } |
|
205 val future = |
|
206 if (thread) { |
|
207 Future.thread(name = Isabelle_Thread.make_name(base = "invoke_scala"))(body) |
|
208 } |
|
209 else Future.fork(body) |
|
210 futures += (id -> future) |
205 true |
211 true |
206 case _ => false |
212 case _ => false |
207 } |
213 } |
208 } |
214 } |
209 |
215 |