🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: vmsnet.tpu
Article #38

RE: Getting a logical within a TPU procedure

#38
From: Paul Neubauer
Date: Tue, 11 Aug 1992 13:54
51 lines
2827 bytes
Ken Fairfield wrote:
>Date: 11 Aug 92 00:20:03 GMT
>From: fairfield@slacvx.slac.stanford.edu
>Message-id: <1992Aug10.162003.1@slacvx.slac.stanford.edu>
>In article <1992Aug10.170858.25498@news.cs.brandeis.edu>, gorokhovsky@binah.cc.
b
>randeis.edu writes:
>> I need to get a logical from within a TPU procedure. Is there a way to do it
>> other than using FILE_PARSE (which uppercases the value it gets)?  Any
>> suggetsions will be appreciated.  I will summarize to the net whatever replie
s
>> I get.
>
>    Since this question has come up in vmsnet.tpu _several_ times already,
>I whipped up an example TPU$CALLUSER routine (in Fortran) to interface
>directly to the $TRNLNM system service.  The source is appended below my
>signature.

...
>!+
>!  SYS$TRNLNM is case-sensitive, apparently, so make a local uppercased
>!  version of INSTR.
>!-
...
>        ISS = SYS$TRNLNM (,'LNM$FILE_DEV',LOCAL(1:LLCL),,ITMLST)

Ken doesn't usually miss much, but in this particular case (:-) there
is a simple option that causes the logical name match to be case
blind:

        ISS = SYS$TRNLNM (LNM$M_CASE_BLIND,'LNM$FILE_DEV',LOCAL(1:LLCL),,ITMLST)

You may have to %INCLUDE some additional system file (I don't use
FORTRAN often enough to remember which file contains which constant
(LNM$M_CASE_BLIND)), but that should not be difficult to find out.

The last time this topic came up, I posted similar source in Pascal
and also Arne Vajhxj's C source.  Hunter Goatley also indicated that
there is a MACRO version in the FLIST sources and someone else
"promised" to write a COBOL version.  I would guess that FORTRAN
compilers are as common as anything, but if anyone needs similar
source in a different language (due to lack of compiler or whatever)
there are alternatives available.  BTW, has anyone out there seen an
Alpha (open)VMS machine yet?  How will these routines be rewritten for
Alpha?  I assume that list structures like Ken's ITMLST structure or
functions like IADDRESS will need to be changed for Alpha.

        Paul
========
Paul Neubauer   00PRNEUBAUER@BSUVAX1.BITNET     00prneubauer@leo.bsuvc.bsu.edu
                00prneubauer@bsu-ucs.UUCP       neubauer@bsu-cs.UUCP
Technical Details
Message-ID: <9208111415.AA14508@depot.cis.ksu.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!moe.ksu.ksu.edu!deimos.cis.ksu.edu!mccall!info-tpu-newsgate!list

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!moe.ksu.ksu.edu!deimos.cis.ksu.edu!mccall!info-tpu-newsgate!list
Newsgroups: vmsnet.tpu
Subject: RE: Getting a logical within a TPU procedure
Message-ID: <9208111415.AA14508@depot.cis.ksu.edu>
From: Paul Neubauer <00prneubauer%bsuvax1.bitnet@shsu.edu>
Date: Tue, 11 Aug 1992 08:54 EST
Reply-To: Paul Neubauer <00PRNEUBAUER%BSUVAX1.BITNET@SHSU.edu>
Organization: The Internet
Return-Path: <TPU-Mgr@SHSU.edu>
Errors-To: TPU-Mgr@SHSU.edu
X-Listname: Text Processing Utility (TPU) Language Discussion List
Original_To: INFOTPU
Lines: 51