There is a \== operator which means "not exactly equal to".
Bill
On Mon, 10 Mar 2008 12:45:14 -0600, Todd Burch <[EMAIL PROTECTED]> wrote:
>Actually, "<>" gave me the same false positive that "=" did. Changing the
>comparison to strictly equal worked fine.
>
>I am writing a rexx exec to parse some assembler listings to compare field
>offsets in DSECTS across product releases. For the intent of my compare,
>comparing the "0000E0" and "0000E8" as two strings was my intent. However,
>rexx decides, for whatever reason, (probably because they "can" be numeric)
>that they are not strings.
>
>(I'm just happy it also doesn't consider ("zero" = "oh") to be equal too!)
>
>Converting the offsets to hex or decimal would have also avoided the
>problem, but it was overhead I didn't want to spend.
>
>Todd
>
>
>> -----Original Message-----
>> From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
>> Behalf Of John P. Baker
>> Sent: Monday, March 10, 2008 11:29 AM
>> To: [email protected]
>> Subject: Re: Rexx bug?
>>
>> Ulrich,
>>
>> As long as his intent is a simple equality/inequality test, "=="/"<>" will
>> work fine, in so far as the offsets are both presented with the same
>> length
>> and in the same case. A requirement for x2d(...) will only arise if the
>> offsets are presented with the possibility of differing lengths, differing
>> cases, or if a comparative magnitude test is required (<, <=, >=, or >).
>>
>> John P. Baker
>>
>> -----Original Message-----
>> From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
>> Behalf
>> Of Ulrich Krueger
>> Sent: 03/10/2008 1:00 PM
>> To: [email protected]
>> Subject: Re: Rexx bug?
>>
>> Todd,
>> What is your intent with this comparison?
>> Do you want to compare two quoted character strings or do you want to
>> compare the numeric (hexadecimal) values?
>> If the latter, shouldn't you have coded either
>> offset1 = "0000E0"X;
>> offset2 = "0000E8"X;
>> Or
>> offset1 = x2d("0000E0");
>> offset2 = x2d("0000E8");
>> instead?
>>
>> Regards,
>> Ulrich Krueger
>>
>>
>> No virus found in this incoming message.
>> Checked by AVG.
>> Version: 7.5.518 / Virus Database: 269.21.7/1322 - Release Date: 3/9/2008
>> 12:17 PM
>>
>
>No virus found in this outgoing message.
>Checked by AVG.
>Version: 7.5.518 / Virus Database: 269.21.7/1322 - Release Date: 3/9/2008
>12:17 PM
>
>
----------------------------------------------------------------------
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