Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
why3
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
121
Issues
121
List
Boards
Labels
Service Desk
Milestones
Merge Requests
15
Merge Requests
15
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Why3
why3
Commits
e2434596
Commit
e2434596
authored
Feb 21, 2013
by
Jean-Christophe Filliâtre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
WhyML documentation: old/at, evaluation order
parent
34612387
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
1 deletion
+19
-1
Makefile.in
Makefile.in
+1
-1
doc/syntaxref.tex
doc/syntaxref.tex
+13
-0
doc/term_old_at.bnf
doc/term_old_at.bnf
+5
-0
No files found.
Makefile.in
View file @
e2434596
...
...
@@ -1218,7 +1218,7 @@ ifeq (@enable_doc@,yes)
doc
:
doc/manual.pdf doc/html/index.html
BNF
=
qualid label constant operator term
type
formula theory theory2
\
why_file spec
expr
expr2 module whyml_file
why_file spec
expr
expr2 module whyml_file
term_old_at
BNFTEX
=
$(
addprefix
doc/,
$(
addsuffix
_bnf.tex,
$(BNF)
))
doc/%_bnf.tex
:
doc/%.bnf doc/bnf
...
...
doc/syntaxref.tex
View file @
e2434596
...
...
@@ -179,6 +179,13 @@ is given in Figure~\ref{fig:bnf:spec}.
\caption
{
Specification clauses in programs.
}
\label
{
fig:bnf:spec
}
\end{figure}
Within specifications, terms are extended with new constructs
\verb
|
old
|
and
\verb
|
at
|
:
\begin{center}
\framebox
{
\input
{
./term
_
old
_
at
_
bnf.tex
}}
\end{center}
Within a postcondition,
$
\verb
|old|~t
$
refers to the value of term
$
t
$
in the prestate. Within the scope of a code mark
$
L
$
,
the term
$
\verb
|at|~t~
\verb
|'|L
$
refers to the value of term
$
t
$
at the program
point corresponding to
$
L
$
.
\subsection
{
Expressions
}
...
...
@@ -196,6 +203,12 @@ Figure~\ref{fig:bnf:expra} and~Figure~\ref{fig:bnf:exprb}.
\label
{
fig:bnf:exprb
}
\end{figure}
In applications, arguments are evaluated from right to left.
This includes applications of infix operators, with the only exception of
lazy operators
\verb
|
&&
|
and
\verb
+
||
+
that evaluate from left to
right, lazily.
% In the following we describe the informal semantics of each
% constructs, and provide the corresponding rule for computing the
% weakest precondition.
...
...
doc/term_old_at.bnf
0 → 100644
View file @
e2434596
\begin{syntax}
term ::= ... ;
| "old" term ;
| "at" term "'" uident ;
\end{syntax}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment