aboutsummaryrefslogtreecommitdiff
path: root/src/algebra/si.spad.pamphlet
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2011-03-09 23:54:10 +0000
committerdos-reis <gdr@axiomatics.org>2011-03-09 23:54:10 +0000
commit8c47810df65c610513d4be825bd6ee9a56f97f9f (patch)
tree7117bf9c5177324de1e4a012b635ed667dec817f /src/algebra/si.spad.pamphlet
parentccd024277fb8eab4a8b22ed160f4da1609dd94e9 (diff)
downloadopen-axiom-8c47810df65c610513d4be825bd6ee9a56f97f9f.tar.gz
* algebra/catdef.spad.pamphlet (StepThrough) [nextItem]: Now
return Maybe %. * algebra/ffcat.spad.pamphlet: Propagate change. * algebra/fmod.spad.pamphlet: Likewise. * algebra/fraction.spad.pamphlet: Likewise. * algebra/integer.spad.pamphlet: Likewise. * algebra/pfbr.spad.pamphlet: Likewise. * algebra/polycat.spad.pamphlet: Likewise. * algebra/si.spad.pamphlet: Likewise.
Diffstat (limited to 'src/algebra/si.spad.pamphlet')
-rw-r--r--src/algebra/si.spad.pamphlet8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/algebra/si.spad.pamphlet b/src/algebra/si.spad.pamphlet
index ded2a935..085cc0fe 100644
--- a/src/algebra/si.spad.pamphlet
+++ b/src/algebra/si.spad.pamphlet
@@ -109,10 +109,10 @@ IntegerNumberSystem(): Category ==
init() == 0
-- iterates in order 0,1,-1,2,-2,3,-3,...
- nextItem(n) ==
- zero? n => 1
- n>0 => -n
- 1-n
+ nextItem n ==
+ zero? n => just 1
+ n > 0 => just(-n)
+ just(1-n)
patternMatch(x, p, l) ==
patternMatch(x, p, l)$PatternMatchIntegerNumberSystem(%)