Skip to content

Commit

Permalink
lib: change runErrorT to runExceptT to match Haskell code
Browse files Browse the repository at this point in the history
  • Loading branch information
yanok authored and lsf37 committed Sep 4, 2018
1 parent 378717b commit 0044c57
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions lib/HaskellLib_H.thy
Original file line number Diff line number Diff line change
Expand Up @@ -177,14 +177,14 @@ definition
"catMaybes \<equiv> (map the) \<circ> (filter isJust)"

definition
"runErrorT \<equiv> id"
"runExceptT \<equiv> id"

declare Just_def[simp] Nothing_def[simp] fromJust_def[simp]
isJust_def[simp] tail_def[simp] head_def[simp]
error_def[simp] reverse_def[simp] isNothing_def[simp]
maybeApply_def[simp] maybe_def[simp]
foldR_def[simp] elem_def[simp] notElem_def[simp]
catMaybes_def[simp] runErrorT_def[simp]
catMaybes_def[simp] runExceptT_def[simp]

definition
"headM L \<equiv> (case L of (h # t) \<Rightarrow> return h | _ \<Rightarrow> fail)"
Expand Down
2 changes: 1 addition & 1 deletion proof/crefine/ARM/Syscall_C.thy
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ lemma handleInvocation_def2:
| Inl (Inr preempt) \<Rightarrow> throwError preempt
od
od"
apply (simp add: handleInvocation_def Syscall_H.syscall_def runErrorT_def
apply (simp add: handleInvocation_def Syscall_H.syscall_def runExceptT_def
liftE_bindE cong: sum.case_cong)
apply (rule ext, (rule bind_apply_cong [OF refl])+)
apply (clarsimp simp: bind_assoc split: sum.split)
Expand Down
2 changes: 1 addition & 1 deletion proof/crefine/ARM_HYP/Syscall_C.thy
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ lemma handleInvocation_def2:
| Inl (Inr preempt) \<Rightarrow> throwError preempt
od
od"
apply (simp add: handleInvocation_def Syscall_H.syscall_def runErrorT_def
apply (simp add: handleInvocation_def Syscall_H.syscall_def runExceptT_def
liftE_bindE cong: sum.case_cong)
apply (rule ext, (rule bind_apply_cong [OF refl])+)
apply (clarsimp simp: bind_assoc split: sum.split)
Expand Down
2 changes: 1 addition & 1 deletion proof/crefine/X64/Syscall_C.thy
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ lemma handleInvocation_def2:
| Inl (Inr preempt) \<Rightarrow> throwError preempt
od
od"
apply (simp add: handleInvocation_def Syscall_H.syscall_def runErrorT_def
apply (simp add: handleInvocation_def Syscall_H.syscall_def runExceptT_def
liftE_bindE cong: sum.case_cong)
apply (rule ext, (rule bind_apply_cong [OF refl])+)
apply (clarsimp simp: bind_assoc split: sum.split)
Expand Down

0 comments on commit 0044c57

Please sign in to comment.