Lines Matching defs:dst

164 do_hvis(wchar_t *dst, wint_t c, int flags, wint_t nextc, const wchar_t *extra)
172 dst = do_svis(dst, c, flags, nextc, extra);
174 *dst++ = L'%';
175 *dst++ = xtoa(((unsigned int)c >> 4) & 0xf);
176 *dst++ = xtoa((unsigned int)c & 0xf);
179 return dst;
187 do_mvis(wchar_t *dst, wint_t c, int flags, wint_t nextc, const wchar_t *extra)
196 *dst++ = L'=';
197 *dst++ = XTOA(((unsigned int)c >> 4) & 0xf);
198 *dst++ = XTOA((unsigned int)c & 0xf);
200 dst = do_svis(dst, c, flags, nextc, extra);
201 return dst;
208 do_mbyte(wchar_t *dst, wint_t c, int flags, wint_t nextc, int iswextra)
213 *dst++ = L'\\'; *dst++ = L'n';
214 return dst;
216 *dst++ = L'\\'; *dst++ = L'r';
217 return dst;
219 *dst++ = L'\\'; *dst++ = L'b';
220 return dst;
222 *dst++ = L'\\'; *dst++ = L'a';
223 return dst;
225 *dst++ = L'\\'; *dst++ = L'v';
226 return dst;
228 *dst++ = L'\\'; *dst++ = L't';
229 return dst;
231 *dst++ = L'\\'; *dst++ = L'f';
232 return dst;
234 *dst++ = L'\\'; *dst++ = L's';
235 return dst;
237 *dst++ = L'\\'; *dst++ = L'0';
239 *dst++ = L'0';
240 *dst++ = L'0';
242 return dst;
260 *dst++ = L'\\';
261 *dst++ = c;
262 return dst;
267 *dst++ = L'\\';
268 *dst++ = (u_char)(((uint32_t)(u_char)c >> 6) & 03) + L'0';
269 *dst++ = (u_char)(((uint32_t)(u_char)c >> 3) & 07) + L'0';
270 *dst++ = (c & 07) + L'0';
273 *dst++ = L'\\';
277 *dst++ = L'M';
281 *dst++ = L'^';
283 *dst++ = L'?';
285 *dst++ = c + L'@';
287 *dst++ = L'-';
288 *dst++ = c;
292 return dst;
297 * dst: Pointer to the destination buffer
305 do_svis(wchar_t *dst, wint_t c, int flags, wint_t nextc, const wchar_t *extra)
313 *dst++ = c;
314 return dst;
324 dst = do_mbyte(dst, (wint_t)(
329 return dst;
353 wchar_t *dst, *d;
360 if ((dst = calloc(len + MAXEXTRAS, sizeof(*dst))) == NULL)
363 if ((flags & VIS_NOLOCALE) || mbsrtowcs(dst, &src, len, &mbstate) == (size_t)-1) {
366 dst[i] = (wchar_t)(u_char)src[i];
367 d = dst + len;
369 d = dst + wcslen(dst);
386 return dst;
398 wchar_t *dst, *src, *pdst, *psrc, *start, *extra;
447 dst = pdst;
520 for (start = dst; len > 0; len--) {
522 dst = (*f)(dst, c, flags, len >= 1 ? *src : L'\0', extra);
523 if (dst == NULL) {
530 *dst = L'\0';
542 for (dst = start; len > 0; len--) {
544 clen = wcrtomb(mbdst, *dst, &mbstate);
559 if ((*dst & wmsk) || i == 0)
561 (uint64_t)(*dst & bmsk) >>
572 dst++;
715 * strvis - visually encode characters from src into dst
718 * expansion. The length of dst, not including the trailing NULL,
742 * strvisx - visually encode characters from src into dst
745 * expansion. The length of dst, not including the trailing NULL,
748 * Strvisx encodes exactly len characters from src into dst.