Skip to content

Latest commit

 

History

History
38 lines (25 loc) · 853 Bytes

equals-sign-chaining.md

File metadata and controls

38 lines (25 loc) · 853 Bytes

code pal for ABAP > Equals Sign Chaining

Equals Sign Chaining

What is the Intent of the Check?

This check identifies sequenced assignments as they usually confuse the reader.

"anti-pattern
x = y = z

How to solve the issue?

Break it in multiple rows:

y = z.
x = y.

Alternatively, you can use the xsdbool if the target is a comparison:

x = xsdbool( y = z ).

What to do in case of exception?

In exceptional cases, you can suppress this finding by using the pseudo-comment "#EC EQUALS_CHAINING which should be placed after the attribution:

x = y = z.        "#EC EQUALS_CHAINING

Further Readings & Knowledge