Path: utzoo!attcan!uunet!husc6!rutgers!ucsd!ucbvax!HMCVAX.BITNET!JWILKINSON From: JWILKINSON@HMCVAX.BITNET (Philosopher and Confuser) Newsgroups: comp.os.vms Subject: Re: Using STR$CONCAT in Pascal Message-ID: <8808080426.AA01618@ucbvax.berkeley.edu> Date: 7 Aug 88 13:12:00 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 28 > From: COLEMAN%UMBSKY.BITNET@MITVMA.MIT.EDU > Subject: Calling STR$CONCAT from Pascal. > > Has anyone ever gotten the RTL function STR$CONCAT to work in Pascal? > I've used many other RTL functions from Pascal but this function simply does > not want to work like it's supposed to. (I've tried several different > variations; PACKED ARRAY [1..#] OF CHAR, VARYING [#] OF CHAR, CLASS_S > variable attributes, etc, etc... Nothing works!) You probably have not satisfied the "descriptor" requirement needed for arguments 2 through n by making the formal parameters class_s strings. Declaring the routine as below should make things work. Program Concatenate (Output); Var Result : Varying [80] Of Char; Function STR$CONCAT ( Var DstStr : Varying [length1] Of Char; SrcStr : [Class_s, List] Packed Array [Lower1..Upper1:Integer] Of Char) : Unsigned; External; Begin STR$CONCAT (Result, 'Complete ', 'Confusion'); Writeln ('Result = ', Result); End. JaW (jwilkinson@hmcvax.bitnet)