Home | History | Annotate | Download | only in ed

Lines Matching defs:sub

1 /*	$NetBSD: sub.c,v 1.8 2025/09/17 20:35:11 rillig Exp $	*/
3 /* sub.c: This file contains the substitution routines for the ed
34 static char *rcsid = "@(#)sub.c,v 1.1 1994/02/01 00:34:44 alm Exp";
36 __RCSID("$NetBSD: sub.c,v 1.8 2025/09/17 20:35:11 rillig Exp $");
239 char *sub = rhbuf;
241 for (; sub - rhbuf < rhbufi; sub++)
242 if (*sub == '&') {
248 } else if (*sub == '\\' && '1' <= *++sub && *sub <= '9' &&
249 (n = *sub - '0') <= re_nsub) {
257 rbuf[off++] = *sub;