A bit of library clean-up
This commit is contained in:
10
lib/list.tri
10
lib/list.tri
@@ -157,8 +157,6 @@ partition_ = y (self pred xs trues falses :
|
||||
|
||||
partition = pred xs : partition_ pred xs t t
|
||||
|
||||
partition = pred xs : partition_ pred xs t t
|
||||
|
||||
strLength = length
|
||||
strAppend = append
|
||||
strEq? = equal?
|
||||
@@ -191,11 +189,11 @@ contains? = y (self needle haystack :
|
||||
|
||||
lines_ = y (self str :
|
||||
matchList
|
||||
(acc current : append acc [(reverse current)])
|
||||
(acc current : snoc (reverse current) acc)
|
||||
(h r :
|
||||
acc current :
|
||||
matchBool
|
||||
(self r (append acc [(reverse current)]) t)
|
||||
(self r (snoc (reverse current) acc) t)
|
||||
(self r acc (pair h current))
|
||||
(equal? h 10))
|
||||
str)
|
||||
@@ -213,14 +211,14 @@ words_ = y (self str :
|
||||
(acc current :
|
||||
matchBool
|
||||
acc
|
||||
(append acc [(reverse current)])
|
||||
(snoc (reverse current) acc)
|
||||
(emptyList? current))
|
||||
(h r :
|
||||
acc current :
|
||||
matchBool
|
||||
(matchBool
|
||||
(self r acc current)
|
||||
(self r (append acc [(reverse current)]) t)
|
||||
(self r (snoc (reverse current) acc) t)
|
||||
(emptyList? current))
|
||||
(self r acc (pair h current))
|
||||
(equal? h 32))
|
||||
|
||||
Reference in New Issue
Block a user