[Info-vax] Notable VMS "feature"
David Froble
davef at tsoft-inc.com
Sat Jan 9 02:36:22 EST 2016
Tom Adams wrote:
> On Thursday, January 7, 2016 at 4:56:54 PM UTC-5, David Froble wrote:
>> VAXman- @SendSpamHere.ORG wrote:
>>> In article <4779702f-8074-4cdd-b809-1cf36c20a162 at googlegroups.com>, Tom Adams <tadamsmar at gmail.com> writes:
>>>> On Thursday, January 7, 2016 at 2:28:33 PM UTC-5, VAXman- wrote:
>>>>> In article <aec0b901-1099-48bb-899c-70d9952e1010 at googlegroups.com>, Tom Adams <tadamsmar at gmail.com> writes:
>>>>>> I have defined a logical name that I cannot deassign
>>>>>>
>>>>>> A logical name that is 255 characters long that ends with a colon.
>>>>>>
>>>>>> Here's a command procedure than will do it.
>>>>>>
>>>>>> $A = "X"
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = A+A
>>>>>> $A = F$EXTRACT(0,254,A)
>>>>>> $A = A+":"
>>>>>> $WRITE SYS$OUTPUT "''F$LENGTH(A)'"
>>>>>> $DEFINE 'A FOOBAR
>>>>>> $!Cannot deassign using the name because the colon is stripped
>>>>>> $ON ERROR THEN CONTINUE
>>>>>> $DEASS 'A
>>>>>> $!Cannot deassign by adding a extra colon because the name it too long
>>>>>> $B = A+':'
>>>>>> $DEASS 'B
>>>>>>
>>>>>> Is there anyway to get rid of this logical name other than logging out?
>>>>>>
>>>>> PROGRAM MY_TERMINAL
>>>>> IMPLICIT NONE
>>>>>
>>>>> INCLUDE '($DSCDEF)'
>>>>> INCLUDE '($JPIDEF)'
>>>>> INCLUDE '($STSDEF)'
>>>>> INCLUDE '(LIB$ROUTINES)'
>>>>> INCLUDE '(STR$ROUTINES)'
>>>>>
>>>>> INTEGER*4 STATUS
>>>>>
>>>>> RECORD /DSCDEF1/ LOGICAL
>>>>>
>>>>> LOGICAL.DSC$W_MAXSTRLEN = 0
>>>>> LOGICAL.DSC$B_DTYPE = DSC$K_DTYPE_T
>>>>> LOGICAL.DSC$B_CLASS = DSC$K_CLASS_D
>>>>> LOGICAL.DSC$A_POINTER = 0
>>>>>
>>>>> STATUS = STR$DUPL_CHAR(LOGICAL,254,%REF('X'))
>>>>> IF (.NOT.(STATUS.AND.STS$M_SUCCESS)) THEN
>>>>> CALL SYS$EXIT(%VAL(STATUS))
>>>>> ENDIF
>>>>>
>>>>> STATUS = STR$APPEND(LOGICAL,%DESCR(':'))
>>>>> IF (.NOT.(STATUS.AND.STS$M_SUCCESS)) THEN
>>>>> CALL SYS$EXIT(%VAL(STATUS))
>>>>> ENDIF
>>>>>
>>>>> STATUS = LIB$DELETE_LOGICAL(LOGICAL,)
>>>>> CALL SYS$EXIT(%VAL(STATUS))
>>>>>
>>>>> END
>>> Oops. I just noticed I forgot to change the program name. Oh, the horrors
>>> of cut and paste!
>>>
>> See, even Brian isn't infallible ....
>>
>> :-)
>>
>>
>> Then there is the obvious, just shoot the fool that set up a logical name
>> anywhere near that long ....
>
> Try this!:
>
> define :: ::
No!
More information about the Info-vax
mailing list