[Info-vax] CRTL and RMS vs SSIO

Stephen Hoffman seaohveh at hoffmanlabs.invalid
Fri Oct 8 11:27:36 EDT 2021


On 2021-10-07 23:15:19 +0000, Craig A. Berry said:

> On 10/7/21 1:30 PM, Stephen Hoffman wrote:
>> On 2021-10-07 17:16:03 +0000, Dave Froble said:
> 
> 
>>> I don't use C, so I don't know much about it.  But isn't this 
>>> capability already available?
>> 
>> The C standard functions—the equivalent of the BASIC calls OPEN, READ, 
>> WRITE, et al—are via RMS. There's no knob to tell C "don't do that".
> 
> You're pretending that you don't know about the foo="bar" options on 
> the CRTL open/fopen/creat calls.  Yes, it's all via RMS, but you can 
> tell it to do or not do certain things. And the feature logicals, of 
> course, but it might be dinnertime in your time zone and I wouldn't 
> want to give you indigestion :-).

I need to pretend harder, or to forget harder, then. I'm sufficiently 
familiar with those C options and with the acc routines and with my 
always-favorite C feature logical names and the lib$initialize psect 
fun to often prefer use of $qio or $io_perform when suppression of RMS 
"helpfulness" is sought, yes. Even with all those knobs, "well, there's 
egg and bacon; egg sausage and bacon; egg and RMS; egg bacon and RMS; 
egg bacon sausage and RMS; RMS bacon sausage and RMS; RMS egg RMS bacon 
and RMS; RMS sausage RMS bacon RMS..."  "Do you have anything without 
RMS (getting "helpful")?"  https://vimeo.com/329001211

Too many C design quirks awaiting the unwary or the uninitiated here, 
too; where you have to add options to remove platform-specific oddities 
(see above), where basename works for Unix specs but not for OpenVMS 
specs, how select only works for IP, where VFC is the default 
sequential file creation format, the need for the moving target that is 
lib$initialize, and the decc$to_vms and decc$from_vms calling 
conventions. And suchlike.

This is part of why I'd prefer to see a new C standard library within 
the port, and to relegate the existing standard library for use by 
existing apps.

> But from BASIC, yes, I think you have to write wrappers around the CRTL 
> functions and then call them from BASIC, or at least that's what I did 
> the one time I had to write stream files from BASIC.

I'd expect there's BASIC code around that doesn't handle TCP streams 
all that well, either. Similar issues. Punched cards are really 
entrenched all through OpenVMS.


-- 
Pure Personal Opinion | HoffmanLabs LLC 




More information about the Info-vax mailing list