?? RIGHT := 110 ??                                                                                            
?? NEWTITLE := 'NOS/VE:  Object Library Generator' ??                                                         
MODULE ocm$$module_attributes;                                                                                
                                                                                                              
                                                                                                              
                                                                                                              
{ PURPOSE:                                                                                                    
{   To retrieve information about all or part of the contents of a object                                     
{   file or library.                                                                                          
                                                                                                              
  VAR                                                                                                         
    command_status: ost$status;                                                                               
                                                                                                              
?? PUSH (LISTEXT := ON) ??                                                                                    
*copyc cle$ecc_miscellaneous                                                                                  
*copyc llt$load_module                                                                                        
*copyc llt$object_module                                                                                      
*copyc oce$library_generator_errors                                                                           
*copyc oct$attribute_keyword_set                                                                              
*copyc oct$display_toggles                                                                                    
*copyc oct$name_list                                                                                          
*copyc oct$new_library_module_list                                                                            
*copyc oct$object_code_utility_types                                                                          
*copyc oct$olg_scratch_seq                                                                                    
*copyc oct$open_file_list                                                                                     
?? POP ??                                                                                                     
*copyc clp$evaluate_parameters                                                                                
*copyc clp$make_list_value                                                                                    
*copyc ocp$build_module_attributes                                                                            
*copyc ocp$generate_message                                                                                   
*copyc ocp$obtain_library_list                                                                                
*copyc ocp$obtain_object_file                                                                                 
*copyc ocp$search_nlm_tree                                                                                    
*copyc ocp$search_object_file                                                                                 
*copyc ocp$search_open_file_list                                                                              
*copyc ocp$sort_name_list                                                                                     
*copyc osp$append_status_parameter                                                                            
*copyc osp$set_status_abnormal                                                                                
                                                                                                              
*copyc ocv$global_display_toggles                                                                             
*copyc ocv$module_attribute_keys                                                                              
*copyc ocv$nlm_list                                                                                           
*copyc ocv$olg_scratch_seq                                                                                    
?? OLDTITLE ??                                                                                                
?? NEWTITLE := '[XDCL] ocp$$module_attributes', EJECT ??                                                      
                                                                                                              
{ PURPOSE:                                                                                                    
{   Function processor for the CREOL $MODULE_ATTRIBUTES function.                                             
                                                                                                              
  PROCEDURE [XDCL] ocp$$module_attributes                                                                     
    (    parameter_list: clt$parameter_list;                                                                  
     VAR work_area: ^clt$work_area;                                                                           
     VAR result: ^clt$data_value;                                                                             
     VAR status: ost$status);                                                                                 
                                                                                                              
?? NEWTITLE := 'collect_modules_from_current', EJECT ??                                                       
                                                                                                              
{ PURPOSE:                                                                                                    
{   Convert the modules parameter of the function to a list of modules from                                   
{   the current library.                                                                                      
                                                                                                              
    PROCEDURE collect_modules_from_current                                                                    
      (    modules: ^clt$data_value;                                                                          
       VAR module_list: oct$name_list;                                                                        
       VAR status: ost$status);                                                                               
                                                                                                              
?? NEWTITLE := 'collect_modules', EJECT ??                                                                    
                                                                                                              
{ PURPOSE:                                                                                                    
{   Generate a list of modules from the current library from the specified                                    
{   module range.                                                                                             
                                                                                                              
      PROCEDURE collect_modules                                                                               
        (    first_module: pmt$program_name;                                                                  
             last_module: pmt$program_name;                                                                   
         VAR module_list: oct$name_list;                                                                      
         VAR status: ost$status);                                                                             
                                                                                                              
                                                                                                              
        VAR                                                                                                   
          current_module: pmt$program_name,                                                                   
          last_new_module: ^oct$name_list,                                                                    
          last_old_module: ^oct$name_list,                                                                    
          module_found: boolean,                                                                              
          nlm: ^oct$new_library_module_list;                                                                  
                                                                                                              
                                                                                                              
        last_old_module := ^module_list;                                                                      
        WHILE last_old_module^.link <> NIL DO                                                                 
          last_old_module := last_old_module^.link;                                                           
        WHILEND;                                                                                              
        last_new_module := last_old_module;                                                                   
                                                                                                              
                                                                                                              
        ocp$search_nlm_tree (first_module, nlm, module_found);                                                
        IF NOT module_found THEN                                                                              
          IF first_module = last_module THEN                                                                  
            osp$set_status_abnormal (oc, oce$w_module_not_found, first_module, status);                       
          ELSE                                                                                                
            osp$set_status_abnormal (oc, oce$w_subrange_module_not_found, first_module, status);              
            osp$append_status_parameter (osc$status_parameter_delimiter, first_module, status);               
            osp$append_status_parameter (osc$status_parameter_delimiter, last_module, status);                
          IFEND;                                                                                              
          ocp$generate_message (status);                                                                      
          osp$set_status_abnormal (oc, oce$e_some_modules_not, 'found', command_status);                      
          RETURN;                                                                                             
        IFEND;                                                                                                
                                                                                                              
        REPEAT                                                                                                
          IF nlm^.name = osc$null_name THEN                                                                   
            IF last_module <> osc$null_name THEN                                                              
              osp$set_status_abnormal (oc, oce$e_range_module_2_not_found, last_module, status);              
              osp$append_status_parameter (osc$status_parameter_delimiter, first_module, status);             
              ocp$generate_message (status);                                                                  
              osp$set_status_abnormal (oc, oce$e_some_modules_not, 'found', command_status);                  
            IFEND;                                                                                            
            RETURN;                                                                                           
          IFEND;                                                                                              
                                                                                                              
          current_module := nlm^.name;                                                                        
                                                                                                              
          NEXT last_new_module^.link IN ocv$olg_scratch_seq;                                                  
          last_new_module := last_new_module^.link;                                                           
          IF last_new_module = NIL THEN                                                                       
            osp$set_status_abnormal (oc, oce$e_internal_olg_seg_overflow, '', status);                        
            RETURN;                                                                                           
          IFEND;                                                                                              
                                                                                                              
          last_new_module^.name := current_module;                                                            
          last_new_module^.link := NIL;                                                                       
                                                                                                              
          nlm := nlm^.f_link;                                                                                 
        UNTIL current_module = last_module;                                                                   
                                                                                                              
      PROCEND collect_modules;                                                                                
?? OLDTITLE ??                                                                                                
?? EJECT ??                                                                                                   
                                                                                                              
                                                                                                              
      VAR                                                                                                     
        a_module: ^clt$data_value,                                                                            
                                                                                                              
        first_module: pmt$program_name,                                                                       
        last_module: pmt$program_name;                                                                        
                                                                                                              
                                                                                                              
      IF (modules <> NIL) AND (modules^.kind = clc$list) THEN                                                 
        a_module := modules;                                                                                  
                                                                                                              
        REPEAT                                                                                                
          IF a_module^.element_value^.kind = clc$range THEN                                                   
            first_module := a_module^.element_value^.low_value^.program_name_value;                           
            last_module := a_module^.element_value^.high_value^.program_name_value;                           
          ELSE                                                                                                
            first_module := a_module^.element_value^.program_name_value;                                      
            last_module := first_module;                                                                      
          IFEND;                                                                                              
                                                                                                              
          collect_modules (first_module, last_module, module_list, status);                                   
          IF NOT status.normal THEN                                                                           
            RETURN;                                                                                           
          IFEND;                                                                                              
          a_module := a_module^.link;                                                                         
        UNTIL a_module = NIL;                                                                                 
                                                                                                              
      ELSE                                                                                                    
        IF ocv$nlm_list^.f_link^.name = osc$null_name THEN                                                    
          osp$set_status_abnormal (oc, oce$w_no_modules_on_current_lib, '', status);                          
          RETURN;                                                                                             
        IFEND;                                                                                                
                                                                                                              
        first_module := ocv$nlm_list^.f_link^.name;                                                           
        last_module := ocv$nlm_list^.b_link^.name;                                                            
                                                                                                              
        collect_modules (first_module, last_module, module_list, status);                                     
      IFEND;                                                                                                  
                                                                                                              
                                                                                                              
    PROCEND collect_modules_from_current;                                                                     
?? OLDTITLE ??                                                                                                
?? NEWTITLE := 'collect_modules_from_external', EJECT ??                                                      
                                                                                                              
{ PURPOSE:                                                                                                    
{   Convert the modules parameter of the function to a list of modules from                                   
{   the external library.                                                                                     
                                                                                                              
    PROCEDURE collect_modules_from_external                                                                   
      (    modules: ^clt$data_value;                                                                          
       VAR input_file: ^oct$open_file_list;                                                                   
       VAR module_list: oct$name_list;                                                                        
       VAR status: ost$status);                                                                               
                                                                                                              
?? NEWTITLE := 'collect_modules', EJECT ??                                                                    
                                                                                                              
{ PURPOSE:                                                                                                    
{   Generate a list of modules from the external library from the specified                                   
{   module range.                                                                                             
                                                                                                              
      PROCEDURE collect_modules                                                                               
        (    first_module: pmt$program_name;                                                                  
             last_module: pmt$program_name;                                                                   
         VAR module_list: oct$name_list;                                                                      
         VAR status: ost$status);                                                                             
                                                                                                              
                                                                                                              
        VAR                                                                                                   
          current_module: pmt$program_name,                                                                   
          last_new_module: ^oct$name_list,                                                                    
          last_old_module: ^oct$name_list,                                                                    
          module_found: boolean,                                                                              
          nlm: ^oct$new_library_module_list;                                                                  
                                                                                                              
                                                                                                              
        last_old_module := ^module_list;                                                                      
        WHILE last_old_module^.link <> NIL DO                                                                 
          last_old_module := last_old_module^.link;                                                           
        WHILEND;                                                                                              
        last_new_module := last_old_module;                                                                   
                                                                                                              
        input_file^.current_module := 1;                                                                      
        ocp$search_object_file (first_module, module_found, input_file);                                      
        IF NOT module_found THEN                                                                              
          IF first_module = last_module THEN                                                                  
            osp$set_status_abnormal (oc, oce$w_module_not_found, first_module, status);                       
          ELSE                                                                                                
            osp$set_status_abnormal (oc, oce$w_subrange_module_not_found, first_module, status);              
            osp$append_status_parameter (osc$status_parameter_delimiter, first_module, status);               
            osp$append_status_parameter (osc$status_parameter_delimiter, last_module, status);                
          IFEND;                                                                                              
          ocp$generate_message (status);                                                                      
          osp$set_status_abnormal (oc, oce$e_some_modules_not, 'found', command_status);                      
          RETURN;                                                                                             
        IFEND;                                                                                                
                                                                                                              
        REPEAT                                                                                                
          IF input_file^.current_module > UPPERBOUND (input_file^.directory^) THEN                            
            IF last_module <> osc$null_name THEN                                                              
              osp$set_status_abnormal (oc, oce$e_range_module_2_not_found, last_module, status);              
              osp$append_status_parameter (osc$status_parameter_delimiter, first_module, status);             
              ocp$generate_message (status);                                                                  
              osp$set_status_abnormal (oc, oce$e_some_modules_not, 'found', command_status);                  
            IFEND;                                                                                            
            RETURN;                                                                                           
          IFEND;                                                                                              
                                                                                                              
          current_module := input_file^.directory^ [input_file^.current_module].name;                         
                                                                                                              
          NEXT last_new_module^.link IN ocv$olg_scratch_seq;                                                  
          last_new_module := last_new_module^.link;                                                           
          IF last_new_module = NIL THEN                                                                       
            osp$set_status_abnormal (oc, oce$e_internal_olg_seg_overflow, '', status);                        
            RETURN;                                                                                           
          IFEND;                                                                                              
                                                                                                              
          last_new_module^.name := current_module;                                                            
          last_new_module^.link := NIL;                                                                       
                                                                                                              
          input_file^.current_module := input_file^.current_module + 1;                                       
        UNTIL current_module = last_module;                                                                   
                                                                                                              
      PROCEND collect_modules;                                                                                
?? OLDTITLE ??                                                                                                
?? EJECT ??                                                                                                   
                                                                                                              
                                                                                                              
      VAR                                                                                                     
        a_module: ^clt$data_value,                                                                            
                                                                                                              
        first_module: pmt$program_name,                                                                       
        last_module: pmt$program_name;                                                                        
                                                                                                              
                                                                                                              
      IF (modules <> NIL) AND (modules^.kind = clc$list) THEN                                                 
        a_module := modules;                                                                                  
                                                                                                              
        REPEAT                                                                                                
          IF a_module^.element_value^.kind = clc$range THEN                                                   
            first_module := a_module^.element_value^.low_value^.program_name_value;                           
            last_module := a_module^.element_value^.high_value^.program_name_value;                           
          ELSE                                                                                                
            first_module := a_module^.element_value^.program_name_value;                                      
            last_module := first_module;                                                                      
          IFEND;                                                                                              
                                                                                                              
          collect_modules (first_module, last_module, module_list, status);                                   
          IF NOT status.normal THEN                                                                           
            RETURN;                                                                                           
          IFEND;                                                                                              
          a_module := a_module^.link;                                                                         
        UNTIL a_module = NIL;                                                                                 
                                                                                                              
      ELSE                                                                                                    
                                                                                                              
        first_module := input_file^.directory^ [1].name;                                                      
        last_module := osc$null_name;                                                                         
                                                                                                              
        collect_modules (first_module, last_module, module_list, status);                                     
      IFEND;                                                                                                  
                                                                                                              
                                                                                                              
    PROCEND collect_modules_from_external;                                                                    
?? OLDTITLE ??                                                                                                
?? EJECT ??                                                                                                   
                                                                                                              
{ FUNCTION (OCM$CREOL_$MODA) $module_attributes (                                                             
{   modules: any of                                                                                           
{     key all keyend                                                                                          
{     list of any of                                                                                          
{       program_name                                                                                          
{       range of program_name                                                                                 
{     anyend                                                                                                  
{   anyend = all                                                                                              
{   library: any of                                                                                           
{     key new_library keyend                                                                                  
{     file                                                                                                    
{   anyend = new_library                                                                                      
{   attributes: any of                                                                                        
{       key all keyend                                                                                        
{       list of key                                                                                           
{         header, program_attributes                                                                          
{         (kind, k)                                                                                           
{         (name, n)                                                                                           
{         (abort_file, af)                                                                                    
{         (aliases, alias, al)                                                                                
{         (application_identifier, ai)                                                                        
{         (arithmetic_loss_of_significance, alos)                                                             
{         (arithmetic_overflow, ao)                                                                           
{         (availability, a)                                                                                   
{         (comment, commentary)                                                                               
{         (components, component, c)                                                                          
{         (creation_date_time, cdt)                                                                           
{         (debug_input, di)                                                                                   
{         (debug_mode, dm)                                                                                    
{         (debug_output, do)                                                                                  
{         (divide_fault, df)                                                                                  
{         (entry_points, entry_point, ep)                                                                     
{         (exponent_overflow, eo)                                                                             
{         (exponent_underflow, eu)                                                                            
{         (fp_indefinite, fpi, fi)                                                                            
{         (fp_loss_of_significance, fplos, flos)                                                              
{         (generator, g)                                                                                      
{         (generator_version, gv)                                                                             
{         (invalid_bdp_data, ibdpd, ibd)                                                                      
{         (libraries, library, l)                                                                             
{         (load_map, lm)                                                                                      
{         (load_map_options, load_map_option, lmo)                                                            
{         (log_option, lo)                                                                                    
{         (module_kind, mk)                                                                                   
{         (modules, module, m)                                                                                
{         (natural_language, nl)                                                                              
{         (object_files, object_file, of)                                                                     
{         (online_manual, om)                                                                                 
{         (preset_value, pv)                                                                                  
{         (references, reference, r)                                                                          
{         (scope, s)                                                                                          
{         (stack_size, ss)                                                                                    
{         (starting_procedure, sp)                                                                            
{         (status_codes, status_code, sc)                                                                     
{         (system_command_name, scn),                                                                         
{         (termination_error_level, tel)                                                                      
{         (text_kind, tk)                                                                                     
{       keyend                                                                                                
{     anyend = header)                                                                                        
                                                                                                              
?? PUSH (LISTEXT := ON) ??                                                                                    
?? FMT (FORMAT := OFF) ??                                                                                     
                                                                                                              
  VAR                                                                                                         
    pdt: [STATIC, READ, cls$declaration_section] record                                                       
      header: clt$pdt_header,                                                                                 
      names: array [1 .. 3] of clt$pdt_parameter_name,                                                        
      parameters: array [1 .. 3] of clt$pdt_parameter,                                                        
      type1: record                                                                                           
        header: clt$type_specification_header,                                                                
        qualifier: clt$union_type_qualifier,                                                                  
        type_size_1: clt$type_specification_size,                                                             
        element_type_spec_1: record                                                                           
          header: clt$type_specification_header,                                                              
          qualifier: clt$keyword_type_qualifier,                                                              
          keyword_specs: array [1 .. 1] of clt$keyword_specification,                                         
        recend,                                                                                               
        type_size_2: clt$type_specification_size,                                                             
        element_type_spec_2: record                                                                           
          header: clt$type_specification_header,                                                              
          qualifier: clt$list_type_qualifier_v2,                                                              
          element_type_spec: record                                                                           
            header: clt$type_specification_header,                                                            
            qualifier: clt$union_type_qualifier,                                                              
            type_size_1: clt$type_specification_size,                                                         
            element_type_spec_1: record                                                                       
              header: clt$type_specification_header,                                                          
            recend,                                                                                           
            type_size_2: clt$type_specification_size,                                                         
            element_type_spec_2: record                                                                       
              header: clt$type_specification_header,                                                          
              qualifier: clt$range_type_qualifier,                                                            
              element_type_spec: record                                                                       
                header: clt$type_specification_header,                                                        
              recend,                                                                                         
            recend,                                                                                           
          recend,                                                                                             
        recend,                                                                                               
        default_value: string (3),                                                                            
      recend,                                                                                                 
      type2: record                                                                                           
        header: clt$type_specification_header,                                                                
        qualifier: clt$union_type_qualifier,                                                                  
        type_size_1: clt$type_specification_size,                                                             
        element_type_spec_1: record                                                                           
          header: clt$type_specification_header,                                                              
          qualifier: clt$keyword_type_qualifier,                                                              
          keyword_specs: array [1 .. 1] of clt$keyword_specification,                                         
        recend,                                                                                               
        type_size_2: clt$type_specification_size,                                                             
        element_type_spec_2: record                                                                           
          header: clt$type_specification_header,                                                              
        recend,                                                                                               
        default_value: string (11),                                                                           
      recend,                                                                                                 
      type3: record                                                                                           
        header: clt$type_specification_header,                                                                
        qualifier: clt$union_type_qualifier,                                                                  
        type_size_1: clt$type_specification_size,                                                             
        element_type_spec_1: record                                                                           
          header: clt$type_specification_header,                                                              
          qualifier: clt$keyword_type_qualifier,                                                              
          keyword_specs: array [1 .. 1] of clt$keyword_specification,                                         
        recend,                                                                                               
        type_size_2: clt$type_specification_size,                                                             
        element_type_spec_2: record                                                                           
          header: clt$type_specification_header,                                                              
          qualifier: clt$list_type_qualifier_v2,                                                              
          element_type_spec: record                                                                           
            header: clt$type_specification_header,                                                            
            qualifier: clt$keyword_type_qualifier,                                                            
            keyword_specs: array [1 .. 96] of clt$keyword_specification,                                      
          recend,                                                                                             
        recend,                                                                                               
        default_value: string (6),                                                                            
      recend,                                                                                                 
    recend := [                                                                                               
    [1,                                                                                                       
    [93, 10, 13, 4, 49, 58, 392],                                                                             
    clc$function, 3, 3, 0, 0, 0, 0, 0, 'OCM$CREOL_$MODA'], [                                                  
    ['ATTRIBUTES                     ',clc$nominal_entry, 3],                                                 
    ['LIBRARY                        ',clc$nominal_entry, 2],                                                 
    ['MODULES                        ',clc$nominal_entry, 1]],                                                
    [                                                                                                         
{ PARAMETER 1                                                                                                 
    [3, clc$normal_usage_entry, clc$non_secure_parameter,                                                     
    $clt$parameter_spec_methods[clc$specify_positionally],                                                    
    clc$pass_by_value, clc$immediate_evaluation,                                                              
  clc$standard_parameter_checking, 113, clc$optional_default_parameter, 0, 3],                                
{ PARAMETER 2                                                                                                 
    [2, clc$normal_usage_entry, clc$non_secure_parameter,                                                     
    $clt$parameter_spec_methods[clc$specify_positionally],                                                    
    clc$pass_by_value, clc$immediate_evaluation,                                                              
  clc$standard_parameter_checking, 67, clc$optional_default_parameter, 0, 11],                                
{ PARAMETER 3                                                                                                 
    [1, clc$normal_usage_entry, clc$non_secure_parameter,                                                     
    $clt$parameter_spec_methods[clc$specify_positionally],                                                    
    clc$pass_by_value, clc$immediate_evaluation,                                                              
  clc$standard_parameter_checking, 3639, clc$optional_default_parameter, 0, 6                                 
  ]],                                                                                                         
{ PARAMETER 1                                                                                                 
    [[1, 0, clc$union_type], [[clc$keyword_type,                                                              
    clc$list_type],                                                                                           
    FALSE, 2],                                                                                                
    44, [[1, 0, clc$keyword_type], [1], [                                                                     
      ['ALL                            ', clc$nominal_entry,                                                  
  clc$normal_usage_entry, 1]]                                                                                 
      ],                                                                                                      
    49, [[1, 0, clc$list_type], [33, 1, clc$max_list_size, 0, FALSE, FALSE],                                  
        [[1, 0, clc$union_type], [[clc$program_name_type,                                                     
        clc$range_type],                                                                                      
        FALSE, 2],                                                                                            
        3, [[1, 0, clc$program_name_type]],                                                                   
        10, [[1, 0, clc$range_type], [3],                                                                     
            [[1, 0, clc$program_name_type]]                                                                   
          ]                                                                                                   
        ]                                                                                                     
      ]                                                                                                       
    ,                                                                                                         
    'all'],                                                                                                   
{ PARAMETER 2                                                                                                 
    [[1, 0, clc$union_type], [[clc$file_type, clc$keyword_type],                                              
    FALSE, 2],                                                                                                
    44, [[1, 0, clc$keyword_type], [1], [                                                                     
      ['NEW_LIBRARY                    ', clc$nominal_entry,                                                  
  clc$normal_usage_entry, 1]]                                                                                 
      ],                                                                                                      
    3, [[1, 0, clc$file_type]]                                                                                
    ,                                                                                                         
    'new_library'],                                                                                           
{ PARAMETER 3                                                                                                 
    [[1, 0, clc$union_type], [[clc$keyword_type,                                                              
    clc$list_type],                                                                                           
    FALSE, 2],                                                                                                
    44, [[1, 0, clc$keyword_type], [1], [                                                                     
      ['ALL                            ', clc$nominal_entry,                                                  
  clc$normal_usage_entry, 1]]                                                                                 
      ],                                                                                                      
    3575, [[1, 0, clc$list_type], [3559, 1, clc$max_list_size, 0, FALSE, FALSE]                               
  ,                                                                                                           
        [[1, 0, clc$keyword_type], [96], [                                                                    
        ['A                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 10],                                                                                
        ['ABORT_FILE                     ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 5],                                                                                 
        ['AF                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 5],                                                                                 
        ['AI                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 7],                                                                                 
        ['AL                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 6],                                                                                 
        ['ALIAS                          ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 6],                                                                                 
        ['ALIASES                        ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 6],                                                                                 
        ['ALOS                           ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 8],                                                                                 
        ['AO                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 9],                                                                                 
        ['APPLICATION_IDENTIFIER         ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 7],                                                                                 
        ['ARITHMETIC_LOSS_OF_SIGNIFICANCE', clc$nominal_entry,                                                
  clc$normal_usage_entry, 8],                                                                                 
        ['ARITHMETIC_OVERFLOW            ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 9],                                                                                 
        ['AVAILABILITY                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 10],                                                                                
        ['C                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 12],                                                                                
        ['CDT                            ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 13],                                                                                
        ['COMMENT                        ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 11],                                                                                
        ['COMMENTARY                     ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 11],                                                                                
        ['COMPONENT                      ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 12],                                                                                
        ['COMPONENTS                     ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 12],                                                                                
        ['CREATION_DATE_TIME             ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 13],                                                                                
        ['DEBUG_INPUT                    ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 14],                                                                                
        ['DEBUG_MODE                     ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 15],                                                                                
        ['DEBUG_OUTPUT                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 16],                                                                                
        ['DF                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 17],                                                                                
        ['DI                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 14],                                                                                
        ['DIVIDE_FAULT                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 17],                                                                                
        ['DM                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 15],                                                                                
        ['DO                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 16],                                                                                
        ['ENTRY_POINT                    ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 18],                                                                                
        ['ENTRY_POINTS                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 18],                                                                                
        ['EO                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 19],                                                                                
        ['EP                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 18],                                                                                
        ['EU                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 20],                                                                                
        ['EXPONENT_OVERFLOW              ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 19],                                                                                
        ['EXPONENT_UNDERFLOW             ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 20],                                                                                
        ['FI                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 21],                                                                                
        ['FLOS                           ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 22],                                                                                
        ['FPI                            ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 21],                                                                                
        ['FPLOS                          ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 22],                                                                                
        ['FP_INDEFINITE                  ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 21],                                                                                
        ['FP_LOSS_OF_SIGNIFICANCE        ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 22],                                                                                
        ['G                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 23],                                                                                
        ['GENERATOR                      ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 23],                                                                                
        ['GENERATOR_VERSION              ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 24],                                                                                
        ['GV                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 24],                                                                                
        ['HEADER                         ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 1],                                                                                 
        ['IBD                            ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 25],                                                                                
        ['IBDPD                          ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 25],                                                                                
        ['INVALID_BDP_DATA               ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 25],                                                                                
        ['K                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 3],                                                                                 
        ['KIND                           ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 3],                                                                                 
        ['L                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 26],                                                                                
        ['LIBRARIES                      ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 26],                                                                                
        ['LIBRARY                        ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 26],                                                                                
        ['LM                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 27],                                                                                
        ['LMO                            ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 28],                                                                                
        ['LO                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 29],                                                                                
        ['LOAD_MAP                       ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 27],                                                                                
        ['LOAD_MAP_OPTION                ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 28],                                                                                
        ['LOAD_MAP_OPTIONS               ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 28],                                                                                
        ['LOG_OPTION                     ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 29],                                                                                
        ['M                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 31],                                                                                
        ['MK                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 30],                                                                                
        ['MODULE                         ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 31],                                                                                
        ['MODULES                        ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 31],                                                                                
        ['MODULE_KIND                    ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 30],                                                                                
        ['N                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 4],                                                                                 
        ['NAME                           ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 4],                                                                                 
        ['NATURAL_LANGUAGE               ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 32],                                                                                
        ['NL                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 32],                                                                                
        ['OBJECT_FILE                    ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 33],                                                                                
        ['OBJECT_FILES                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 33],                                                                                
        ['OF                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 33],                                                                                
        ['OM                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 34],                                                                                
        ['ONLINE_MANUAL                  ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 34],                                                                                
        ['PRESET_VALUE                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 35],                                                                                
        ['PROGRAM_ATTRIBUTES             ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 2],                                                                                 
        ['PV                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 35],                                                                                
        ['R                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 36],                                                                                
        ['REFERENCE                      ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 36],                                                                                
        ['REFERENCES                     ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 36],                                                                                
        ['S                              ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 37],                                                                                
        ['SC                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 40],                                                                                
        ['SCN                            ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 41],                                                                                
        ['SCOPE                          ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 37],                                                                                
        ['SP                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 39],                                                                                
        ['SS                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 38],                                                                                
        ['STACK_SIZE                     ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 38],                                                                                
        ['STARTING_PROCEDURE             ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 39],                                                                                
        ['STATUS_CODE                    ', clc$alias_entry,                                                  
  clc$normal_usage_entry, 40],                                                                                
        ['STATUS_CODES                   ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 40],                                                                                
        ['SYSTEM_COMMAND_NAME            ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 41],                                                                                
        ['TEL                            ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 42],                                                                                
        ['TERMINATION_ERROR_LEVEL        ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 42],                                                                                
        ['TEXT_KIND                      ', clc$nominal_entry,                                                
  clc$normal_usage_entry, 43],                                                                                
        ['TK                             ', clc$abbreviation_entry,                                           
  clc$normal_usage_entry, 43]]                                                                                
        ]                                                                                                     
      ]                                                                                                       
    ,                                                                                                         
    'header']];                                                                                               
                                                                                                              
?? FMT (FORMAT := ON) ??                                                                                      
?? POP ??                                                                                                     
                                                                                                              
    CONST                                                                                                     
      p$modules = 1,                                                                                          
      p$library = 2,                                                                                          
      p$attributes = 3;                                                                                       
                                                                                                              
    VAR                                                                                                       
      pvt: array [1 .. 3] of clt$parameter_value;                                                             
                                                                                                              
    VAR                                                                                                       
      temp: integer,                                                                                          
      attribute: ^clt$data_value,                                                                             
      dummy: boolean,                                                                                         
      external_file: boolean,                                                                                 
      header_only: boolean,                                                                                   
      high: oct$module_attribute_keywords,                                                                    
      input_file: ^oct$open_file_list,                                                                        
      low: oct$module_attribute_keywords,                                                                     
      module_list: ^oct$name_list,                                                                            
      nlm: ^oct$new_library_module_list,                                                                      
      pick: oct$module_attribute_keywords,                                                                    
      selected_keywords: oct$attribute_keyword_set,                                                           
      value: ^^clt$data_value;                                                                                
                                                                                                              
                                                                                                              
    status.normal := TRUE;                                                                                    
    command_status.normal := TRUE;                                                                            
                                                                                                              
    RESET ocv$olg_scratch_seq;                                                                                
                                                                                                              
    clp$evaluate_parameters (parameter_list, #SEQ (pdt), NIL, ^pvt, status);                                  
    IF NOT status.normal THEN                                                                                 
      RETURN;                                                                                                 
    IFEND;                                                                                                    
                                                                                                              
    PUSH module_list;                                                                                         
    module_list^.link := NIL;                                                                                 
                                                                                                              
    IF pvt [p$library].value^.kind = clc$file THEN                                                            
      external_file := TRUE;                                                                                  
                                                                                                              
      ocp$obtain_object_file (pvt [p$library].value^.file_value^, input_file, status);                        
      IF NOT status.normal THEN                                                                               
        RETURN;                                                                                               
      IFEND;                                                                                                  
                                                                                                              
      collect_modules_from_external (pvt [p$modules].value, input_file, module_list^, status);                
      IF NOT status.normal THEN                                                                               
        RETURN;                                                                                               
      IFEND;                                                                                                  
                                                                                                              
    ELSE                                                                                                      
      external_file := FALSE;                                                                                 
                                                                                                              
      collect_modules_from_current (pvt [p$modules].value, module_list^, status);                             
      IF NOT status.normal THEN                                                                               
        RETURN;                                                                                               
      IFEND;                                                                                                  
    IFEND;                                                                                                    
                                                                                                              
    attribute := pvt [p$attributes].value;                                                                    
    IF attribute^.kind = clc$keyword THEN                                                                     
      selected_keywords := $oct$attribute_keyword_set [occ$kwd_all];                                          
    ELSE                                                                                                      
      selected_keywords := $oct$attribute_keyword_set [];                                                     
      WHILE attribute <> NIL DO                                                                               
        high := UPPERBOUND (ocv$module_attribute_keys);                                                       
        low := LOWERBOUND (ocv$module_attribute_keys);                                                        
        REPEAT                                                                                                
          temp := high + low;                                                                                 
          pick := temp DIV 2;                                                                                 
          IF attribute^.element_value^.keyword_value = ocv$module_attribute_keys [pick].name THEN             
            high := pick;                                                                                     
            low := pick;                                                                                      
          ELSEIF attribute^.element_value^.keyword_value > ocv$module_attribute_keys [pick].name THEN         
            low := pick + 1;                                                                                  
          ELSE                                                                                                
            high := pick - 1;                                                                                 
          IFEND;                                                                                              
        UNTIL high = low;                                                                                     
        selected_keywords := selected_keywords + $oct$attribute_keyword_set                                   
              [ocv$module_attribute_keys [low].attribute];                                                    
        attribute := attribute^.link;                                                                         
      WHILEND;                                                                                                
    IFEND;                                                                                                    
                                                                                                              
    module_list := module_list^.link;                                                                         
    result := NIL;                                                                                            
    value := ^result;                                                                                         
                                                                                                              
    WHILE module_list <> NIL DO                                                                               
      clp$make_list_value (work_area, value^);                                                                
      IF external_file THEN                                                                                   
        input_file^.current_module := 1;                                                                      
        ocp$search_object_file (module_list^.name, dummy, input_file);                                        
        ocp$build_module_attributes (selected_keywords, input_file^.directory^ [input_file^.current_module],  
              NIL, work_area, value^^.element_value, status);                                                 
      ELSE                                                                                                    
        ocp$search_nlm_tree (module_list^.name, nlm, dummy);                                                  
        ocp$build_module_attributes (selected_keywords, nlm^.description^, nlm^.changed_info, work_area,      
              value^^.element_value, status);                                                                 
      IFEND;                                                                                                  
                                                                                                              
      IF NOT status.normal THEN                                                                               
        RETURN;                                                                                               
      IFEND;                                                                                                  
                                                                                                              
      module_list := module_list^.link;                                                                       
      value := ^value^^.link;                                                                                 
    WHILEND;                                                                                                  
                                                                                                              
    IF result = NIL THEN                                                                                      
      clp$make_list_value (work_area, result);                                                                
    IFEND;                                                                                                    
                                                                                                              
    status := command_status;                                                                                 
                                                                                                              
  PROCEND ocp$$module_attributes;                                                                             
?? OLDTITLE ??                                                                                                
                                                                                                              
MODEND ocm$$module_attributes;                                                                                
