Exception
<% switch Web.getExn () of
Fail msg => %>
Fail: <% Web.htmlNl msg %>
<% | OS.SysErr (name, NONE) => %>
System error: <% Web.html name %>
<% | OS.SysErr (name, SOME syserr) => %>
System error: <% Web.html name %>: <% Web.html (OS.errorName syserr) %>: <% Web.htmlNl (OS.errorMsg syserr) %>
<% | IO.Io {name, function, cause, ...} => %>
IO error: <% Web.html name %> for <% Web.html function %>
Cause: <% Web.html (Init.explain cause) %>
Tokens: <% Web.htmlNl (Init.tokens ()) %>
<% | Init.C.Sql msg => %>
SQL: <% Web.htmlNl msg %>
<% | Init.Access msg => %>
Authorization error: <% Web.htmlNl msg %>
<% | Web.Format s => %>
Format: <% Web.htmlNl s %>
<% | DynLinkage.DynLinkError s => %>
Linking error: <% Web.htmlNl s %>
<% | Init.NeedTos => %>
Our records indicate that you need to agree to our Terms of Service.
<% val ap = #app (Init.getUser ());
App.readTosBody () %>
<% | ex => %>
Unknown exception kind. Backtrace:
<% foreach s in SMLofNJ.exnHistory ex do %>
<% Web.html s %>
<% end
end %>