🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.intel
Article #1938

Re: PLM vs. C for 80286/80386

#1938
From: Tom Neff
Date: Fri, 09 Jun 1989 01:14
36 lines
1576 bytes
In article <409@nbires.nbi.com> maa@nbires.UUCP (Mark Armbrust) writes:
>It's been a while since I've used PL/M, so I may not have the syntax
>quite right, but you can implement variable arguments by passing pointers:
>
>call Printf ("format string", @(arg1, arg2, etc));

Uh, no.  Strings are passed by @address, and the only legal way to
put things in a @(x, y, z...) container is if x and y and z are simple
8-bit constants.

If you want to make an array or structure of pointers to various
things you can do that, e.g.,

	DECLARE
		plist	(100) POINTER;

		...

	plist(0) = @word1;
	plist(1) = @realval;
	plist(2) = @string1;
	plist(3) = NIL;

	CALL printf(@('W1 = %d, R1 = %f, S1 = %s', 0DH, 0AH, 0), @plist);

you could do it, provided someone wrote a printf-style interpreter that
could deal with it (you don't get one with PL/M).

Someone put together a PL/M interface with the iC-86 1.0 (== awful Mark
Williams C) RTL but it didn't strike me as very usable when I tried
it out.
-- 
You may redistribute this article only to those who may freely do likewise.
--
Tom Neff				UUCP:     ...!uunet!bfmny0!tneff
    "Truisms aren't everything."	Internet: tneff@bfmny0.UU.NET
Technical Details
Message-ID: <14393@bfmny0.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!bfmny0!tneff
References: <598@philtis.UUCP> <126@tridom.uucp> <409@nbires.nbi.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!bfmny0!tneff
From: tneff@bfmny0.UUCP (Tom Neff)
Newsgroups: comp.sys.intel
Subject: Re: PLM vs. C for 80286/80386
Keywords: PLM C
Message-ID: <14393@bfmny0.UUCP>
Date: 9 Jun 89 01:14:31 GMT
References: <598@philtis.UUCP> <126@tridom.uucp> <409@nbires.nbi.com>
Reply-To: tneff@bfmny0.UUCP (Tom Neff)
Organization: ^
Lines: 36