File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -86,8 +86,8 @@ stripPrefix :: String -> String -> Maybe String
8686
8787If the string starts with the given prefix, return the portion of the
8888string left after removing it, as a Just value. Otherwise, return Nothing.
89- * `stripPrefix "http:" "http://purescript.org " == Just "//purescript.org"
90- * `stripPrefix "http:" "https://purescript.org " == Nothing
89+ * ` stripPrefix "http:" "http://purescript.org" == Just "//purescript.org" `
90+ * ` stripPrefix "http:" "https://purescript.org" == Nothing `
9191
9292#### ` fromCharArray `
9393
@@ -131,7 +131,7 @@ lastIndexOf :: String -> String -> Maybe Int
131131```
132132
133133Returns the index of the last occurrence of the first string in the
134- second string. Returns ` -1 ` if there is no match.
134+ second string. Returns ` Nothing ` if there is no match.
135135
136136#### ` lastIndexOf' `
137137
Original file line number Diff line number Diff line change @@ -97,8 +97,8 @@ dropWhile p s = drop (count p s) s
9797
9898-- | If the string starts with the given prefix, return the portion of the
9999-- | string left after removing it, as a Just value. Otherwise, return Nothing.
100- -- | * `stripPrefix "http:" "http://purescript.org" == Just "//purescript.org"
101- -- | * `stripPrefix "http:" "https://purescript.org" == Nothing
100+ -- | * `stripPrefix "http:" "http://purescript.org" == Just "//purescript.org"`
101+ -- | * `stripPrefix "http:" "https://purescript.org" == Nothing`
102102stripPrefix :: String -> String -> Maybe String
103103stripPrefix prefix str =
104104 case indexOf prefix str of
@@ -137,7 +137,7 @@ foreign import _indexOf' :: (forall a. a -> Maybe a)
137137 -> Maybe Int
138138
139139-- | Returns the index of the last occurrence of the first string in the
140- -- | second string. Returns `-1 ` if there is no match.
140+ -- | second string. Returns `Nothing ` if there is no match.
141141lastIndexOf :: String -> String -> Maybe Int
142142lastIndexOf = _lastIndexOf Just Nothing
143143
You can’t perform that action at this time.
0 commit comments