You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 25, 2020. It is now read-only.
When an Isabelle instance has been created (using System.create), several threads are started for communicating with Isabelle. These are all non-daemon threads. This means that when the main program ends, the JVM does not return but waits indefinitely.
The following snippets shows the threads that keep the JVM from exiting:
importscala.collection.JavaConverters._valthreadSet=Thread.getAllStackTraces.keySet.asScala
for (t <- threadSet if!t.isDaemon)
println(t.getName)
The output is:
standard_error
standard_output
process_manager
command_input
message_output
process_result
main
Only main should be a non-daemon thread.
(Of course, one can always exit via sys.exit, but that puts the burden on the developer to make sure all possible execution paths end with sys.exit.)