USES clause in conjunction with ASSIGNMENTS.

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

USES clause in conjunction with ASSIGNMENTS.

ThSITC
A warning should be given when the *target* of an assignment (the left
hand side)
in a NetRexx Program *does have the same name as a visible property*
of a module in the USES clause.

example:

class abc
    properties public
       a=3
       b=4

...

class newclass USES abc

b=a+b

*most interesting*:

Left hand side *b* is a new local variable, whilst right hand side *b*
refers to *abc.b*  :-(

Hence, when possible, a *warning shall be issued*, at least ....

Just for common sense ..
Thomas.



_______________________________________________
Ibm-netrexx mailing list
[hidden email]
Online Archive : http://ibm-netrexx.215625.n3.nabble.com/

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: USES clause in conjunction with ASSIGNMENTS.

Kermit Kiser
I was able to duplicate this. I am not sure if it is an error or WAD but
if you think it is a significant issue, you should open a ticket on Kenai.

-- Kermit

On 2015-08-13 12:08 PM, Thomas Schneider wrote:

> A warning should be given when the *target* of an assignment (the left
> hand side)
> in a NetRexx Program *does have the same name as a visible property*
> of a module in the USES clause.
>
> example:
>
> class abc
>    properties public
>       a=3
>       b=4
>
> ...
>
> class newclass USES abc
>
> b=a+b
>
> *most interesting*:
>
> Left hand side *b* is a new local variable, whilst right hand side *b*
> refers to *abc.b*  :-(
>
> Hence, when possible, a *warning shall be issued*, at least ....
>
> Just for common sense ..
> Thomas.
>

_______________________________________________
Ibm-netrexx mailing list
[hidden email]
Online Archive : http://ibm-netrexx.215625.n3.nabble.com/

Loading...