Permalink
Browse files

Add string-compare. Remove implementation notes. Flatten.

  • Loading branch information...
1 parent e18b0f8 commit 666099da9e821f330e8b9d5e33f454f3b70dba65 Carl Gay committed Apr 10, 2012
Showing with 4 additions and 18 deletions.
  1. +4 −18 source/proposals/dep-0004.rst
@@ -145,10 +145,10 @@ Export the following functions from the "strings" module of the
// often useful for strings as well...
concatenate(sequence, #rest more-sequences) => (new-sequence)
- replace-subsequence!(big, small, #key start, end) => (big)
join (parts, separator, #key start, end, key, conjunction) => (string)
- split (string, separator, #key start, end, max, remove-if-empty?) => (strings)
replace-elements!(big, predicate, new-value-fn, #key count) => (big)
+ replace-subsequence!(big, small, #key start, end) => (big)
+ split (string, separator, #key start, end, max, remove-if-empty?) => (strings)
Some observations about this API:
@@ -205,9 +205,6 @@ now, resulting in multiple implementations) or write a ``for`` loop
inline.
-Comparisons
-~~~~~~~~~~~
-
::
char-equal? (char1, char2) => (boolean)
@@ -226,6 +223,8 @@ Comparisons
string-less-ic? (string1, string2, #key start1, end1, start2, end2) => (boolean)
string-greater-ic? (string1, string2, #key start1, end1, start2, end2) => (boolean)
+ string-compare(string1, string2, #key, start1, end1, start2, end2) => (one-of(-1, 0, 1))
+
String and character comparisons, both case-sensitive and ignoring
case (\*-ic?). These default to comparing the entire string but allow
comparing substrings via keyword arguments.
@@ -347,16 +346,3 @@ library:
* Two names from the ``substring-search`` module:
``make-substring-positioner`` and ``make-substring-replacer``.
-
-
-Implementation Notes
-====================
-
-* Copy <character-set> and friends from string-extensions to
- regular-expressions. That's the only place that uses it, and it is
- unlikely to be of much use elsewhere. See conversation in #dylan on
- 2011.12.26.
-
-* Add a README to string-extensions that points out that it has been
- superceded by "strings" and is a purely GD library. Perhaps merge
- it into the ``gwydion`` repository?

0 comments on commit 666099d

Please sign in to comment.