Closed m-tyler closed 1 year ago
There was big change to the internals of the linter and I suspect this is clearly from that. I will look into this.
This code also causes linter warnings to appear but for something that does not seem correct. The semi colon on the SQL statement on a line by itself causes mp reference errors for the proc parameters.
**FREE
Dcl-S MyParm1 Char(1) Const;
Dcl-S MyParm2 Char(1) Const;
exec sql
select 1
from MyTable
Where MyField1 =:MyParm1
and MyField2 = :MyParm2
;
MyProc1();
*INLR = *ON;
Return;
dcl-proc MyProc1;
dcl-pi *n ;
pMyParm1 Char(1) Const;
pMyParm2 Char(1) Const;
end-pi;
exec sql
select 1
from MyTable
Where MyField1 =:pMyParm1
and MyField2 = :pMyParm2
;
end-proc;
Whoops, you must have comments right as I made a release. Can you please share your rpglint.json
config so I can recreate that?
Try out the 0.20.1 release and let me know how it goes. Thanks!
Updated to 0.20.1 and now that linter warning is not present. 😀😀 VERY NICE!!!.
Thanks!!!
P.S. Do you want another issue I have come across with the update to 0.20.1 in this issue or anew issue?
@m-tyler new issue please!! Thanks for everything!
Updating to 0.20.0 I now receive linter warnings for code like this. Is there a new linter rule added for this in 0.20.0 that I need to set? This just an example of code that is longer that has this issue. I like to move the semi colon to its own line for some conditions where I might be adding additional later, it reduces my need to remove and add semi colons when adding additional conditions.
Example of in production code the new linter rules highlight.