diff options
author | dos-reis <gdr@axiomatics.org> | 2010-07-26 16:33:38 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2010-07-26 16:33:38 +0000 |
commit | d05164b7bc0d0998e9e220497386ff7d7cc9a445 (patch) | |
tree | d2aac85e74b965f3fef32d1394aef5d4762901fd /src/algebra/string.spad.pamphlet | |
parent | 2676acdd33957fe60f54ff9ec73fac8b7a6ed705 (diff) | |
download | open-axiom-d05164b7bc0d0998e9e220497386ff7d7cc9a445.tar.gz |
* interp/g-opt.boot ($VMsideEffectFreeOperators): Include new
opcodes %icst0, %icst1, %when, and %ccst.
* interp/g-util.boot: Expand %ccst.
* algebra/alql.spad.pamphlet: Clean up.
* algebra/array1.spad.pamphlet: Likewise.
* algebra/c02.spad.pamphlet: Likewise.
* algebra/d03.spad.pamphlet: Likewise.
* algebra/e04.spad.pamphlet: Likewise.
* algebra/integer.spad.pamphlet: Likewise.
* algebra/si.spad.pamphlet: Likewise.
* algebra/string.spad.pamphlet: Likewise.
Diffstat (limited to 'src/algebra/string.spad.pamphlet')
-rw-r--r-- | src/algebra/string.spad.pamphlet | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/algebra/string.spad.pamphlet b/src/algebra/string.spad.pamphlet index 2469249d..9f2e5883 100644 --- a/src/algebra/string.spad.pamphlet +++ b/src/algebra/string.spad.pamphlet @@ -82,6 +82,7 @@ Character: OrderedFinite() with import %cge: (%,%) -> Boolean from Foreign Builtin import %c2i: % -> NNI from Foreign Builtin import %i2c: NNI -> % from Foreign Builtin + import %ccst: String -> % from Foreign Builtin a = b == %ceq(a,b) a < b == %clt(a,b) @@ -94,9 +95,9 @@ Character: OrderedFinite() with char(n: NNI) == %i2c n ord c == %c2i c random() == char(random(size())$NNI) - space == CHAR(" ", 0$Lisp)$Lisp - quote == CHAR("_" ", 0$Lisp)$Lisp - escape == CHAR("__ ", 0$Lisp)$Lisp + space == %ccst " " + quote == %ccst "_"" + escape == %ccst "__" coerce(c:%):OutputForm == c : OutputForm digit? c == member?(c, digit()) hexDigit? c == member?(c, hexDigit()) @@ -272,7 +273,7 @@ IndexedString(mn:Integer): Export == Implementation where -- new n == MAKE_-FULL_-CVEC(n, space$C)$Lisp new(n, c) == MAKE_-FULL_-CVEC(n, c)$Lisp - empty() == MAKE_-FULL_-CVEC(0$Lisp)$Lisp + empty() == MAKE_-FULL_-CVEC(0@I)$Lisp empty?(s) == Qsize(s) = 0 #s == Qsize(s) s = t == Qequal(s, t) |