previous next top contents index framed top this page unframed
Figure 46–7. rcWrite
| (GENERIC) PROCEDURE rcWrite (MODIFIES STRING s; REPEATABLE INTEGER char); PROCEDURE rcWrite (MODIFIES STRING s; POINTER($area) area; REPEATABLE INTEGER char); |
rcWrite (“reverse cWrite”) concatenates the character char onto the front of the STRING s. In the area form, area specifies the destination area for the resulting STRING if new STRING text is generated; see Section 29.4.
Example 46–8. Use of rcWrite
s := "bc"; rcWrite(s,'a'); # s = "abc" The “reverse” PROCEDURE of Example 46–6 could also be written with rcWrite replacing cWrite and cRead replacing rcRead:
STRING PROCEDURE reverse (STRING s); (although the rcRead/cWrite form would use STRING space more efficiently than the cRead/rcWrite form). |
MAINSAIL Language Manual, Section 46.6