update for new carp
This commit is contained in:
11
redis.carp
11
redis.carp
@@ -34,8 +34,7 @@
|
|||||||
(if (not (num? l))
|
(if (not (num? l))
|
||||||
(Error @"Error decoding bulk string: does not start with length!")
|
(Error @"Error decoding bulk string: does not start with length!")
|
||||||
(Success (Str
|
(Success (Str
|
||||||
(String.prefix-string &(join "\r\n" &(suffix-array &splt 1))
|
(String.prefix &(join "\r\n" &(suffix &splt 1)) (from-string l))))))))
|
||||||
(from-string l))))))))
|
|
||||||
|
|
||||||
(hidden agg)
|
(hidden agg)
|
||||||
(private agg)
|
(private agg)
|
||||||
@@ -72,8 +71,8 @@
|
|||||||
(let [il (from-string &(tail el))]
|
(let [il (from-string &(tail el))]
|
||||||
(if (= -1 il)
|
(if (= -1 il)
|
||||||
(aset-uninitialized! &a idx @"")
|
(aset-uninitialized! &a idx @"")
|
||||||
(let-do [rest (suffix-array &splt (+ i 2))]
|
(let-do [rest (suffix &splt (+ i 2))]
|
||||||
(aset-uninitialized! &a idx (prefix-string &(join "\r\n" &rest) il))
|
(aset-uninitialized! &a idx (String.prefix &(join "\r\n" &rest) il))
|
||||||
(set! i (+ i (agg &rest il))))))
|
(set! i (+ i (agg &rest il))))))
|
||||||
\*
|
\*
|
||||||
(do
|
(do
|
||||||
@@ -143,9 +142,7 @@ For variable port numbers please check out [`open-on`](#open-on).")
|
|||||||
(let [i (String.index-of s \-)]
|
(let [i (String.index-of s \-)]
|
||||||
(if (= i -1)
|
(if (= i -1)
|
||||||
s
|
s
|
||||||
(String.join [(String.prefix-string s i)
|
(String.join [(String.prefix s i) " " (rtreat- (String.suffix s (+ i 1)))]))))
|
||||||
" "
|
|
||||||
(rtreat- (String.suffix-string s (+ i 1)))]))))
|
|
||||||
|
|
||||||
(defndynamic rconv- [args]
|
(defndynamic rconv- [args]
|
||||||
(if (= (length args) 0)
|
(if (= (length args) 0)
|
||||||
|
Reference in New Issue
Block a user