summaryrefslogtreecommitdiff
path: root/do/chop
diff options
context:
space:
mode:
Diffstat (limited to 'do/chop')
-rw-r--r--do/chop40
1 files changed, 0 insertions, 40 deletions
diff --git a/do/chop b/do/chop
deleted file mode 100644
index 377d694bef..0000000000
--- a/do/chop
+++ /dev/null
@@ -1,40 +0,0 @@
-void
-do_chop(astr,TARG)
-register STR *astr;
-register STR *TARG;
-{
- register char *tmps;
- register int i;
- ARRAY *ary;
- HASH *hash;
- HENT *entry;
-
- if (!TARG)
- return;
- if (TARG->str_state == SS_ARY) {
- ary = stab_array(TARG->str_u.str_stab);
- for (i = 0; i <= ary->ary_fill; i++)
- do_chop(astr,ary->ary_array[i]);
- return;
- }
- if (TARG->str_state == SS_HASH) {
- hash = stab_hash(TARG->str_u.str_stab);
- (void)hiterinit(hash);
- /*SUPPRESS 560*/
- while (entry = hiternext(hash))
- do_chop(astr,hiterval(hash,entry));
- return;
- }
- tmps = str_get(TARG);
- if (tmps && TARG->str_cur) {
- tmps += TARG->str_cur - 1;
- str_nset(astr,tmps,1); /* remember last char */
- *tmps = '\0'; /* wipe it out */
- TARG->str_cur = tmps - TARG->str_ptr;
- TARG->str_nok = 0;
- STABSET(TARG);
- }
- else
- str_nset(astr,"",0);
-}
-