Answer B: building on HOL using improvised J syntax
Clarification is good, but I do not like to do it to do it.
My first answer below was largely based on your phrase “brand new syntax,” and I think this is half the answer to this question:
Suppose, hypothetically, that I need a syntax that is very close to the J syntax. What will the Isabelle / HOL require?
My answer:
- Most likely, I would say that you will need to undo most of the syntax for constants, functions, and class types of Isabelle / HOL, which will require extensive editing of the standard Isabelle / HOL distribution to bring it back. And some syntax in Isabelle / HOL, you most likely will not be able to pull out.
- ,
Pure . . .
?
Isabelle/HOL True Artiste.
, parse_translation, Isabelle/ML, . : notation, no_notation, syntax translations, abbreviation, , HOL.
notation, no_notation,
no_notation , . , . , bool ?.
notation , .
plus :: 'a => 'a => 'a :
notation plus (infixl "[+]" 65)
notation (input) plus (infixl "[+]" 65)
notation (output) plus (infixl "[+]" 65)
plus, HOL.
, , - , (input).
notation, , greps THY src/HOL, , .
abbreviation,
, even. - :
notation (input) even ("even _" [1000] 1000)
notation (output) even ("even _" [1000] 999)
"", , even, .
999? , , , declare[[show_brackets]]:
notation even ("even _" [1000] 1000)
, . , , , - .
, abbreviation. abbreviation .
:
abbreviation list_foo :: "'a list => 'a => 'a list" where
"list_foo xs x == x # xs"
notation
list_foo ("_ +#+ _" [65, 65] 64)
. , - (infixl "_ +#+ _" [65, 65] 64). , , Set.thy, , infixl, [65, 65] 64 , .
[65, 65] 64? . .
syntax translations
, . greps . . -, , , , -. , , , , , , , , , , .
Isar, isar-ref.pdf # 175 . , notation PDF .
B
:
" ", (cs.utoronto.ca/~hehner/FMSD)J - , . , Isabelle, .
, -, , , :
, , /HOL , J.
, :
, , J Isabelle/HOL.
, . , , ?
, " , ", , , , , , .
. , .
HOL , - ,
Isabelle/HOL , , , , .
, , , ole, ole imperatic .
, HOL, , - , , .
, , .
J ,
, , 3-, Cormen Leiserson.
Isabelle/HOL . , .
, , , , , J - , , , . , , ++ Java, , . , , , , .
J
, , . ( , ?) , -.
, , , . . .
. , , , .
- , , , , - : " , , X".
, , , , , .
. , .
, , . : " , , /HOL?" , , : " , , , Isabelle/HOL?"
, , . , . . , , , , , - .
L4.verified( AutoCorres)
NICTA L4.verified project. (: sel4.systems, , General Dynamics C4 Systems. , GD, , - , .)
:
, : seL4. 3- 8 700 C.
? ole C? , C . NICTA, , , .
(: AutoCorres NICTA PDF. 1.0, 2014-12-16 . , , . - AutoCorres, , , . , - , C , , . , PhD .)
: ?
PDF .
, , - " ".
, , , .
, , , , , . ? .
, . , .
- : NASA 2014 .
: while loops
, , - , .
5.2.0 While Loop, aPToP.pdf # 76. , 265:
while ¬ x = y = 0 do
if y > 0 then y := y - 1
else (x := x - 1. var· y := n)
, ( " ", , , ).
, . , , , , , , , J.
, , . GitHub " J Isabelle/HOL - , , J- ", .
Coq. ?
, Coq , .
, Google coq.
Ynot.
, J Isabelle/HOL?
. , -, , , , .
, , , .
J, 0 10
J 0, 0 10.
, , - " J Thing", RSS-.
, , J- Isabelle/HOL, , , , .
, RSS- , , , GitHub, 10. - Isabelle/HOL, , , , - .
, , , .
, ( , ), .
, Isabelle ( " " ), , :
, , , , , :
- , , J, Isabelle/Pure ( J ).
- , Isabelle/Isar, ( ?) . ( , .)
, .
, , - J, :
J - , , , .
, , C, Pascal, , , :
- , , , , /HOL.
- ( ?) , J, , Isabelle/Pure,
- Isabelle/HOL, 5 , SML, OCaml, Haskell, Scala Eval (Isabelle/ML),
- Isabelle/HOL, ( ) ,
definition, primrec, datatype fun, , Isabelle/HOL, , ..
, , , , , Isabelle/HOL, , .
, , Isabelle :
HOL .
, Imperative_HOL, .
afp/Collections/Lib/Diff_Array, , , , .
, , , , .
, Isabelle/HOL, , , , Complex_Main.
(L, P) - , L - , P - . , (Isabelle/HOL, Haskell) , , (x, J), x - .
Isabelle/HOL Haskell . , Isabelle/HOL Haskell, , Haskell - , Isabelle/HOL - . , , , - .
, , :
- Haskell - ,
- Isabelle/HOL - ,
- Haskell - , Isabelle/HOL,
- Isabelle/HOL ( ?) Haskell.
. : , . -, , .
, , , , , Isabelle/HOL, , Isabelle2014/src , , , , , - , full blown, , Isabelle/HOL.
.
,
.
, , , : " , - . ?"
Isabelle2014/src
Isabelle2014 - Isabelle2014/src.
src CCL, Cube, CTT .
, , , , , , . , .
C/++ , - C/++?
, C. , , . vcc.codeplex.com/. , , , , .
, C ++ , , , C, .
, , C/++?
- , , , , Scala, , , C, , J, , . , , .
, , .
,
- , , , , , , , , .
. , .
, Isabelle/HOL , , , ML, HOL, , Pure , , HOL, Isabelle, , Isar ( , , ), PIDE , TUM, , CERN (: CERN? ; CERN NICTA, , ), , , ETH , , UIBK ? ? , , .
? , -, . . , , , src, HOWTO , , $9,95 , , , , , , , , Isabelle2014/ , , .
, . , .
, 47 60 HOL.thy:
setup {* Axclass.class_axiomatization (@{binding type}, []) *}
default_sort type
setup {* Object_Logic.add_base_sort @{sort type} *}
axiomatization where fun_arity: "OFCLASS('a ⇒ 'b, type_class)"
instance "fun" :: (type, type) type by (rule fun_arity)
axiomatization where itself_arity: "OFCLASS('a itself, type_class)"
instance itself :: (type) type by (rule itself_arity)
typedecl bool
judgment
Trueprop :: "bool => prop" ("(_)" 5)
. typedecl bool, , , HOL.thy import Pure.
, , , , - x::'a::type:
setup {* Object_Logic.add_base_sort @{sort type} *}
? , . , Isabelle/HOL, 57 HOL.thy . HOL, ? , , , , , , .
, , , . , , , HOL.thy , 2019 . , , HOL.thy, , Pure.
src/Cube. .
: Cube.thy Example.thy. , , , . /HOL.
. Isabelle/HOL , . , , OCaml, Haskell, SML, Haskell Eval.
, , . , , - .