Skip to content

ABAP Keyword Documentation →  ABAP − Release-Specific Changes →  Changes for Release 7.0 

Syntax Cleanup in Release 7.0

For Release 7.0, the ABAP syntax has been cleaned up. Incorrect language constructs, which previously only led to syntax warnings, now cause syntax errors. The profile parameter abap/warn2error_release can be used to control whether the new syntax errors continue to be reported as syntax warnings.

The following tables show the situations that lead to syntax errors as of Release 7.0. An "X" in the final column of the table indicates that the syntax in question already led to a syntax error in classes before Release 7.0.

Error in Language Construct
Program Layout
Statement cannot be reached.
Missing forward declaration of a class with CLASS - DEFERRED
Declarations
Program-internal name with more than 30 characters.
Special characters in a program-internal name outside of Unicode programs.
Single digit as the name of a data object.
Incorrect namespace prefix.
Operational statement within the definition of astructure with BEGIN OF ... END OF.
Reference to a framework program in a publicparameter interface
Reference to a data type of the framework program in the declaration of a public attribute of a global class
Specification of an incompatible or non-convertible value after DEFAULT for a formal parameter.
An interface parameter of a function module, which has been defined both as input and output parameter, was declared with different or generic types.
A type of a type group has the same name as an existing type in ABAP Dictionary.
A constant in a type group has the same name as an existingflat structure or table in ABAP Dictionary.
A macro in atype group does not have the name of the type group as a prefix.
A reserved component name such as the pseudo component table_line is used in a structure in ABAP Dictionary.
Declaration of an internal table with the predefined name screen.
ABAP Objects
Unknown global class or interface after GLOBAL FRIENDS.
Specification of IMPORTING, CHANGING, or RECEIVING with dynamic CREATE OBJECT.
Missing call of the instance constructor of thesuperclass in the instance constructor of asubclass.
Access to an instance component before the call of theinstance constructor of thesuperclass in the instance constructor of asubclass.
Short form static_meth( a ) with a non-unique assignment to a formal parameter.
Fixture method in test class is not private.
Use of the selector ->> instead of theinstance component selector -> when calling interface methods.
Operators and Additions
Invalid one-character operator in a logical expression, which has temporarily been interpreted as an abbreviation, for example, as E for EQ.
AND or OR at the end of alogical expression not followed by a logical expression.
More than one LENGTH addition after DESCRIBE FIELD.
Specification of the addition SORTED BY after COLLECT.
Specification of the addition LANGUAGE after CREATE OBJECT for OLE.
Simultaneous specification of the additions AND SKIP FIRST SCREEN andUSING after CALL TRANSACTION.
Addition OBJECT missing after AUTHORITY-CHECK.
More than ten FIELD additions after AUTHORITY-CHECK.
Operand Positions
Operands not convertible in an assignment that is mapped internally to MOVE.
Operand that cannot be converted to a number at a numeric operand position (for example, after DECIMALS for ASSIGN).
Length less than or equal to zero in the offset/length specification for fields of fixed length.
Empty offset/length specifications.
Superfluous trailing blanks in text field literals.
Line-exceeding text field literal.
Line-exceeding element of a bulleted list.
Invalid use of a text symbol as the target of a call.
Internal table does not have the structure of aselection table in alogical expression after IN.
Assignment of sy-subrc to a CHANGING, EXPORTING, or RETURNING parameter.
Passing of a data object to a formal parameter typed with STRUCTURE in a Unicode program, where theUnicode fragment view does not match completely.
Specification of a data object whose name contains an address specification such as aninstance component selector or anoffset/length specification,without an explicit assignment to a parameter when using EXPORT, IMPORT,or CALL DIALOG.
Internal Tables
Definition of a table type for ahashed table without specifyingUNIQUE before KEY.
Specification of a non-index table after SEARCH.
Incompatible work area for control level processing using internal tables with AT and SUM.
Specification of a component of a structured field symbol as a sort criterion after SORT.
Database Accesses
Columns of type STRING or RAWSTRING in aggregate expressions,grouping,sort keys of SELECT.
Access to a projection view in connection with a correlated subquery.
Too many subqueries in a SELECT statement.
Work area or rows of an internal table are shorter than the structure of the database table when specifying the rows in DELETE dbtab.
Indicator variable in Native SQL, which is not of the external type INT2.
List Statements
Dynamic position specification in WRITEor ULINE without AT.
Negative length specification len after WRITE AT.
Specification of a write-protected data object after HIDE.

Other versions: 7.31 | 7.40 | 7.54


Note

Programs that so far have used the language constructions stated above must now be considered as incorrect. If the respective positions in the program have been executed, runtime errors or undefined states occurred. The current syntax cleanup is intended to avoid error situations like the ones described here, when they can be recognized statically in advance.