Coverage report: /home/runner/work/geb/geb/src/poly/poly.lisp
Kind | Covered | All | % |
expression | 28 | 92 | 30.4 |
branch | 2 | 4 | 50.0 |
Key
Not instrumented
Conditionalized out
Executed
Not executed
Both branches taken
One branch taken
Neither branch taken
1
(in-package :geb.poly.main)
3
(defmethod gapply ((morphism poly:<poly>) object)
4
"My main documentation can be found on [GAPPLY][generic-function]
6
I am the [GAPPLY][generic-function] for [POLY:\\<POLY\\>][class], the
7
OBJECT that I expect is of type NUMBER. [GAPPLY][generic-function] reduces down to
8
ordinary common lisp expressions rather straight forwardly
11
Some examples of me are
14
(in-package :geb.poly)
16
POLY> (gapply (if-zero (- ident ident 1) 10 ident) 5)
17
5 (3 bits, #x5, #o5, #b101)
19
POLY> (gapply (if-zero (- ident ident) 10 ident) 5)
20
10 (4 bits, #xA, #o12, #b1010)
22
POLY> (gapply (- (* 2 ident ident) (* ident ident)) 5)
23
25 (5 bits, #x19, #o31, #b11001)
26
(etypecase-of poly:poly morphism
28
(integer (error "never happens"))
30
(gapply (mcar morphism)
31
(gapply (mcadr morphism) object)))
33
(+ (gapply (mcar morphism) object)
34
(gapply (mcadr morphism) object)))
36
(* (gapply (mcar morphism) object)
37
(gapply (mcadr morphism) object)))
39
(floor (gapply (mcar morphism) object)
40
(gapply (mcadr morphism) object)))
42
(- (gapply (mcar morphism) object)
43
(gapply (mcadr morphism) object)))
45
(mod (gapply (mcar morphism) object)
46
(gapply (mcadr morphism) object)))
47
(poly:if-zero (if (zerop (gapply (predicate morphism) object))
48
(gapply (then morphism) object)
49
(gapply (else morphism) object)))
51
(if (< (gapply (mcar morphism) object)
52
(gapply (mcadr morphism) object))
53
(gapply (then morphism) object)
54
(gapply (else morphism) object)))))
56
(defmethod gapply ((morphism integer) object)
57
"My main documentation can be found on [GAPPLY][generic-function]
59
I am the [GAPPLY][generic-function] for INTEGERs, the
60
OBJECT that I expect is of type NUMBER. I simply return myself.
62
Some examples of me are
65
(in-package :geb.poly)
68
10 (4 bits, #xA, #o12, #b1010)
70
(declare (ignore object))