-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathtypes.go
92 lines (69 loc) · 1.17 KB
/
types.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
package gologic
type lvart struct {
id int
}
type V *lvart
type subs_pair struct {
v V
t interface {}
}
type substitution_map interface {
val_at (V) (interface{}, bool)
with (V, interface{}) substitution_map
count () int
}
type empty_subst_value struct {}
type LookupResult struct {
Var bool
v V
Term bool
t interface{}
}
type SubsTNode struct {
e substitution_map
r *SubsTNode
}
type ConstraintResult uint
const (
No ConstraintResult = iota
Yes
Maybe
)
type Constraint struct {
F func(S) (S, ConstraintResult)
}
type Constraints struct {
first Constraint
rest *Constraints
}
type the_package struct {
s substitution_map
c *SubsTNode
constraint_store *Constraints
}
type S *the_package
type Stream struct {
first S
rest func () *Stream
}
type R *Stream
type Goal func(S) R
type db_record struct {
Entity interface{}
Attribute interface{}
Value interface{}
}
type DBCons struct {
car db_record
cdr *DBCons
}
type DB struct {
c chan func (*DBCons) *DBCons
}
type DBValue struct {
d *DBCons
}
type Symbol struct {
name string
}
type Unique struct {}