aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/documentation/lux/abstract/predicate.lux
blob: 6bf46b7341b169364de0e19f56db98cf9e4b7c70 (plain)
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
(.module:
  [library
   [lux
    ["$" documentation (#+ documentation:)]
    [data
     [text (#+ \n)
      ["%" format (#+ format)]]]]]
  [\\library
   ["." /]])

(documentation: (/.Predicate it)
  "A question that can be asked of a value, yield either false (#0) or true (#1).")

(documentation: /.none
  "A predicate that always fails.")

(documentation: /.or
  "A predicate that meets either predecessor.")

(documentation: /.all
  "A predicate that always succeeds.")

(documentation: /.and
  "A predicate that meets both predecessors.")

(documentation: /.complement
  "The opposite of a predicate.")

(documentation: /.difference
  "A predicate that meeds 'base', but not 'sub'.")

(documentation: /.rec
  "Ties the knot for a recursive predicate.")

(.def: .public documentation
  (.List $.Module)
  ($.module /._
            ""
            [..Predicate
             ..none
             ..or
             ..all
             ..and
             ..complement
             ..difference
             ..rec
             ($.default /.union)
             ($.default /.intersection)
             ($.default /.functor)]
            []))