src/Pure/ML-Systems/ml_debugger_polyml-5.5.3.ML
author wenzelm
Wed, 12 Aug 2015 13:53:51 +0200
changeset 60916 a6e2a667b0a8
parent 60853 b0627cb2e08d
child 60954 eeee8349e9eb
permissions -rw-r--r--
resolve undefined blobs by default, e.g. relevant for ML debugger to avoid reset of breakpoints after reload;
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
60729
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
     1
(*  Title:      Pure/ML/ml_debugger_polyml-5.5.3.ML
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
     2
    Author:     Makarius
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
     3
60853
wenzelm
parents: 60852
diff changeset
     4
ML debugger interface -- for Poly/ML 5.5.3, or later.
60729
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
     5
*)
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
     6
60852
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
     7
signature ML_DEBUGGER =
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
     8
sig
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
     9
  type location
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    10
  val on_entry: (string * location -> unit) option -> unit
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    11
  val on_exit: (string * location -> unit) option -> unit
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    12
  val on_exit_exception: (string * location -> exn -> unit) option -> unit
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    13
  val on_breakpoint: (location * bool Unsynchronized.ref -> unit) option -> unit
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    14
  type state
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    15
  val state: Thread.thread -> state list
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    16
  val debug_function: state -> string
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    17
  val debug_function_arg: state -> ML_Name_Space.valueVal
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    18
  val debug_function_result: state -> ML_Name_Space.valueVal
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    19
  val debug_location: state -> location
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    20
  val debug_name_space: state -> ML_Name_Space.T
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    21
end;
1c51a2ca8204 clarified signature, to make debugger.ML compile with current official ML versions;
wenzelm
parents: 60745
diff changeset
    22
60729
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    23
structure ML_Debugger: ML_DEBUGGER =
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    24
struct
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    25
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    26
(* hooks *)
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    27
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    28
type location = PolyML.location;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    29
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    30
val on_entry = PolyML.DebuggerInterface.setOnEntry;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    31
val on_exit = PolyML.DebuggerInterface.setOnExit;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    32
val on_exit_exception = PolyML.DebuggerInterface.setOnExitException;
60744
4eba53a0ac3d report possible breakpoint positions;
wenzelm
parents: 60730
diff changeset
    33
val on_breakpoint = PolyML.DebuggerInterface.setOnBreakPoint;
60729
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    34
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    35
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    36
(* debugger operations *)
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    37
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    38
type state = PolyML.DebuggerInterface.debugState;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    39
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    40
val state = PolyML.DebuggerInterface.debugState;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    41
val debug_function = PolyML.DebuggerInterface.debugFunction;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    42
val debug_function_arg = PolyML.DebuggerInterface.debugFunctionArg;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    43
val debug_function_result = PolyML.DebuggerInterface.debugFunctionResult;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    44
val debug_location = PolyML.DebuggerInterface.debugLocation;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    45
val debug_name_space = PolyML.DebuggerInterface.debugNameSpace;
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    46
f5989a2c1f67 ML debugger interface;
wenzelm
parents:
diff changeset
    47
end;