[Info-vax] New CEO of VMS Software

Arne Vajhøj arne at vajhoej.dk
Fri Jan 12 19:32:09 EST 2024


On 1/7/2024 3:11 PM, Lawrence D'Oliveiro wrote:
> On Sun, 7 Jan 2024 13:16:19 -0500, Arne Vajhøj wrote:
>> The command line is not a single string on VMS.
> 
> Yes it is. It is passed to the program being activated as a single string
> buffer somewhere in P1 space. LIB$GET_FOREIGN returns a copy of this
> string, and the CLD functions do their parsing on this string as well.

Sure about that?

That is how foreign commands work.

But I do see something else for CLD usage.

$ type cmd.for
       program main
       integer*4 cmdlen
       character*80 cmd
       call lib$get_foreign(cmd,,cmdlen)
       write(*,*) cmd(1:cmdlen)
       end
$ for cmd
$ link cmd
$ cmd :== $sys$disk:[]cmd
$ cmd /q1 /q2 A b "C" "d"
/q1 /q2 A b "C" "d"
$ del/symb/glob cmd
$ type cmd.cld
define verb cmd
     image "sys$disk:[]cmd"
     qualifier q1
     qualifier q2
     qualifier q3
     parameter p1
     parameter p2
     parameter p3
     parameter p4
$ set comm cmd
$ cmd /q1 /q2 A b "C" "d"
/Q1/Q2 A B C d

Arne




More information about the Info-vax mailing list