File: m2l_assstr.c

package info (click to toggle)
m2c 0.6-10.2
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k, lenny
  • size: 2,156 kB
  • ctags: 1,908
  • sloc: ansic: 18,135; sh: 1,590; makefile: 48
file content (18 lines) | stat: -rw-r--r-- 458 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/* Run-time function for Modula-2 string assignment.
   Copyright (C) 1993-1997 (see more details in file COPYING).

   This file is part of Modula-2 translator.  */


/* This function is used only for the 3rd edition of Wirth's book. */

void
m2_assstr (var, str, vlong, strlong)
     register char *var, *str;
     register unsigned int vlong, strlong;
{
  while (vlong--, strlong-- != 0)
    *var++ = (*str++);
  while (vlong-- != 0)
    *var++ = '\0';
}