Phil Sidler wrote:
On Thu, 21 Dec 2006 13:32:02 -0700, Steve Comstock
<[EMAIL PROTECTED]> wrote:
Since the argument list for address linkmvs
is a list (array) of addresses pointing to
halfword prefix strings, I use:
#pragma environment(CLA2)
struct argtable_entry {
short argstring_len;
char argstring[];
};
The c runtime takes care of this for you. You are over analyzing it.
main (int argc, char * argv[]) {
int i;
for (i=1; ++i; i<argc)
printf("%s ", argv[i]);
}
or something similar should do it.
Well, that doesn't feel right. It looks to me like
what you suggest is just standard linkage, which
comes in as a single halfword prefixed string,
for which the C runtime sets up each word in the
string in an array of words and then sets the
count of words.
But here we have coming in an array of addresses,
each pointing to a halfword prefixed string, and
the last address has its leftmost bit set on.
--
Indeed, I tried what you suggested and got a S0C4
(of course, I could have made some kind of an
error in copying or compiling, etc., but I think
I'm closer to right on this one).
Kind regards,
-Steve Comstock
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html