Fix handling of extenstion objects

This commit is contained in:
pfaller@cqse.eu 2017-01-27 10:58:24 +01:00
parent 057f26324b
commit 23b67e1b5b

View File

@ -1104,6 +1104,21 @@ CLASS lcl_objects_program IMPLEMENTATION.
ELSE. ELSE.
* function module RPY_PROGRAM_INSERT cannot handle function group includes * function module RPY_PROGRAM_INSERT cannot handle function group includes
IF strlen( is_progdir-name ) > 30.
" special treatment for extenstions
" if the program name exceeds 30 characters it is not a usual
" ABAP program but might be some extension, which requires the internal
" addition EXTENSION TYPE, see
" http://help.sap.com/abapdocu_751/en/abapinsert_report_internal.htm#!ABAP_ADDITION_1@1@
" This e.g. occurs in case of transportable Code Inspector variants (ending with ===VC)
INSERT REPORT is_progdir-name
FROM it_source
STATE 'I'
EXTENSION TYPE is_progdir-name+30.
IF sy-subrc <> 0.
lcx_exception=>raise( 'error from INSERT REPORT .. EXTENSION TYPE' ).
ENDIF.
ELSE.
INSERT REPORT is_progdir-name INSERT REPORT is_progdir-name
FROM it_source FROM it_source
STATE 'I' STATE 'I'
@ -1111,6 +1126,7 @@ CLASS lcl_objects_program IMPLEMENTATION.
IF sy-subrc <> 0. IF sy-subrc <> 0.
lcx_exception=>raise( 'error from INSERT REPORT' ). lcx_exception=>raise( 'error from INSERT REPORT' ).
ENDIF. ENDIF.
ENDIF.
IF NOT it_tpool[] IS INITIAL. IF NOT it_tpool[] IS INITIAL.
INSERT TEXTPOOL is_progdir-name INSERT TEXTPOOL is_progdir-name