Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

Modifying an object module

The member USELST is added to the library as an object module and modified there by means of a substatement.

/start-assembh -----------------------------------------------------------  (1)

//compile source=*library-element(lib=bsp5.bib,element=uselst), -
//module-lib=bsp5.bib(elemnt=uselst) -------------------------------------  (2)

%  ASS6011 ASSEMBLY TIME: 240 MSEC

%  ASS6018 0 FLAGS, 0 PRIVILEGED FLAGS, 0 MNOTES

%  ASS6019 HIGHEST ERROR-WEIGHT: NO ERRORS

%  ASS6006 LISTING GENERATOR TIME: 453 MSEC

//end

%  ASS6012 END OF ASSEMBH

/start-lms ---------------------------------------------------------------  (3)

//modify-logging-parameters logging=*maximum -----------------------------  (4)

//open-library library=bsp5.bib,mode=*update -----------------------------  (5) 

//show-element-attributes (type=r) ---------------------------------------  (6)

INPUT  LIBRARY= :1OSN:$USER.BSP5.BIB
TYP NAME   VER (VAR#) DATE
(R) USELST @   (0001) 2013-03-01
      1 (R)-ELEMENT(S) IN THIS TABLE OF CONTENTS

(1)

The assembler is called to generate an object module.

(2)

The source program USELST is to be assembled. On error-free assembly, the object module thus generated is written to library BSP5.BIB. The object module automatically receives member type R.

(3)

LMS is called.

(4)

In addition to error messages, positive acknowledgments are also logged.

(5)

Library BSP5.BIB is assigned. It must be opened for reading and writing, otherwise modification of the object module is impossible.

(6)

Display directory for all R-type members. The library now contains object module USELST generated from the assembler run.

//modify-element (element=uselst,type=r) ---------------------------------   (7) 

//add-text-modification address=x ́c0 ́,new-contents= ́aa ́(old= ́ER ́) --------   (8)

//end-modify --------------------------------------------------------------  (9)

INPUT  LIBRARY= :1OSN:$USER.BSP5.BIB
OUTPUT LIBRARY= :1OSN:$USER.BSP5.BIB

INPUT  ELEMENT= (R)USELST/@(0001)/2013-03-01
OUTPUT ELEMENT= (R)USELST/@(0002)/2013-03-01

TEXT-ADR:           000000C0
TEXT BEFORE CHANGE:  E R
                  C5D9
TEXT AFTER  CHANGE:  a a
                  8181 ---------------------------------------------------  (10)

        CORRECT (R)USELST/@(0001)/2013-03-01 AS (R)USELST/@(0002)/2013-03-01
               , OUTPUT REPLACED -----------------------------------------  (11)

//show-element-attributes (type=r) ---------------------------------------  (12)

INPUT  LIBRARY= :1OSN:$USER.BSP5.BIB

TYP NAME   VER (VAR#) DATE

(R) USELST @   (0002) 2013-03-01

      1 (R)-ELEMENT(S) IN THIS TABLE OF CONTENTS

//end --------------------------------------------------------------------  (13)

(7)

Module USELST is to be modified.

(8)

This substatement replaces the text ’ER’ with ’aa’ at address c0.

(9)

Substatement input is terminated.

(10)

The text at address 0000C0 is replaced.

(11)

Message indicating that the change has been made and the original member is replaced by the modified member.

(12)

Display directory for all R-type members. The library now contains the modified object module.

(13)

LMS is terminated.