src/HOL/MicroJava/J/SystemClasses.thy
author paulson <lp15@cam.ac.uk>
Mon, 01 Mar 2021 23:26:27 +0000
changeset 73349 6c2da22c9631
parent 62042 6c6ccf573479
permissions -rw-r--r--
Merge

(*  Title:      HOL/MicroJava/J/SystemClasses.thy
    Author:     Gerwin Klein
    Copyright   2002 Technische Universitaet Muenchen
*)

section \<open>System Classes\<close>

theory SystemClasses imports Decl begin

text \<open>
  This theory provides definitions for the \<open>Object\<close> class,
  and the system exceptions.
\<close>

definition ObjectC :: "'c cdecl" where
  [code_unfold]: "ObjectC \<equiv> (Object, (undefined,[],[]))"

definition NullPointerC :: "'c cdecl" where
  [code_unfold]: "NullPointerC \<equiv> (Xcpt NullPointer, (Object,[],[]))"

definition ClassCastC :: "'c cdecl" where
  [code_unfold]: "ClassCastC \<equiv> (Xcpt ClassCast, (Object,[],[]))"

definition OutOfMemoryC :: "'c cdecl" where
  [code_unfold]: "OutOfMemoryC \<equiv> (Xcpt OutOfMemory, (Object,[],[]))"

definition SystemClasses :: "'c cdecl list" where
  [code_unfold]: "SystemClasses \<equiv> [ObjectC, NullPointerC, ClassCastC, OutOfMemoryC]"

end