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
A
alphaLib
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
POTTIER Francois
alphaLib
Commits
670c7a8f
Commit
670c7a8f
authored
Feb 03, 2017
by
POTTIER Francois
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merged the auxiliary class [scope] into [free].
parent
fd366bf8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
12 deletions
+5
-12
src/KitFa.ml
src/KitFa.ml
+5
-12
No files found.
src/KitFa.ml
View file @
670c7a8f
...
...
@@ -14,23 +14,16 @@
(* -------------------------------------------------------------------------- *)
(* The auxiliary class [
scop
e] defines the environment to be a set of atoms
(* The auxiliary class [
fre
e] defines the environment to be a set of atoms
(the atoms that are currently in scope). It defines the method [extend]
so as to update this set. *)
class
[
'
self
]
scope
=
object
(
_
:
'
self
)
method
private
extend
=
Atom
.
Set
.
add
end
(* -------------------------------------------------------------------------- *)
(* The auxiliary class [free] inherits [scope] and further defines the method
[visit_'fn] so that, at a free name occurrence: -1. if the name is local,
nothing happens; -2. if the name is free, then the method [visit_free] is
invoked. *)
(* Furthermore, this class defines the method [visit_'fn] so that, at a free
name occurrence: -1. if the name is local, nothing happens; -2. if the name
is free, then the method [visit_free] is invoked. *)
class
virtual
[
'
self
]
free
=
object
(
self
:
'
self
)
inherit
[
_
]
scope
method
private
extend
=
Atom
.
Set
.
add
method
private
visit_'fn
env
x
=
if
not
(
Atom
.
Set
.
mem
x
env
)
then
self
#
visit_free
x
...
...
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