Lines Matching refs:strsplit
128 (z <- strsplit(txt, pat)[[1]])
129 stopifnot(eq(z, strsplit(txt, pat, useBytes = TRUE)[[1]]))
130 stopifnot(eq(z, strsplit(txt, pat, fixed = TRUE)[[1]]))
131 stopifnot(eq(z, strsplit(txt, pat, fixed = TRUE, useBytes = TRUE)[[1]]))
132 stopifnot(eq(z, strsplit(txt, pat, perl = TRUE)[[1]]))
133 stopifnot(eq(z, strsplit(txt, pat, perl = TRUE, useBytes = TRUE)[[1]]))
135 (z <- strsplit(txt, "[a-c]")[[1]])
136 stopifnot(eq(z, strsplit(txt, "[a-c]", useBytes = TRUE)[[1]]))
137 stopifnot(eq(z, strsplit(txt, "[a-c]", perl = TRUE)[[1]]))
138 stopifnot(eq(z, strsplit(txt, "[a-c]", perl = TRUE, useBytes = TRUE)[[1]]))
141 z <- strsplit("A text I want to display with spaces", NULL)[[1]]
143 strsplit("A text I want to display with spaces", "")[[1]]))
146 (z <- strsplit(x, "e"))
147 stopifnot(identical(z, strsplit(x, "e", useBytes = TRUE)))
148 stopifnot(identical(z, strsplit(x, "e", fixed = TRUE)))
149 stopifnot(identical(z, strsplit(x, "e", fixed = TRUE, useBytes = TRUE)))
150 stopifnot(identical(z, strsplit(x, "e", perl = TRUE)))
151 stopifnot(identical(z, strsplit(x, "e", perl = TRUE, useBytes = TRUE)))