Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • CMT/v1r19/source/cmt_symbol.cxx

    r3 r1  
    15411541            case Sh :
    15421542              cout << "alias " << name <<
    1543                   "=\"" << temp << "\"";
     1543                  "=\"" << temp <<
     1544                  "\"; export " << name;
    15441545              result = 1;
    15451546              break;
     
    15891590
    15901591//-------------------------------------------------------------
    1591 cmt_string Symbol::build_macro_value (bool display_it) const
     1592cmt_string Symbol::build_macro_value () const
    15921593{
    15931594  cmt_string temp;
    15941595
    1595   if (display_it)
    1596     {
    1597       temp = builder->build_and_display (*this);
    1598     }
    1599   else
    1600     {
    1601       temp = builder->build (*this);
    1602     }
     1596  temp = builder->build (*this);
    16031597
    16041598  return (temp);
     
    16581652  ActionType action = Cmt::get_action ();
    16591653
    1660   cmt_string value = build_macro_value (true);
     1654  cmt_string value = build_macro_value ();
    16611655
    16621656  if ((!Cmt::get_quiet ()) &&
     
    17601754
    17611755//-------------------------------------------------------------
    1762 ValueBuilder::ValueBuilder ()
    1763 {
    1764   m_display_it = false;
    1765 }
    1766 
    1767 //-------------------------------------------------------------
    1768 const cmt_string ValueBuilder::build_and_display (const Symbol& symbol)
    1769 {
    1770   cmt_string temp;
    1771 
    1772   m_display_it = true;
    1773   temp = build (symbol);
    1774   m_display_it = false;
    1775 
    1776   return (temp);
    1777 }
    1778 
    1779 //-------------------------------------------------------------
    17801756const cmt_string SetBuilder::build (const Symbol& symbol,
    17811757                                    const cmt_string& /*tag_name*/)
     
    17841760  static int level = 0;
    17851761
    1786   bool show_it = false;
     1762  int show_it = 0;
    17871763
    17881764  cmt_string temp;
     
    17981774        {
    17991775             // Should not display on recursive calls
    1800           if (level == 0) show_it = m_display_it;
     1776          if (level == 0) show_it = 1;
    18011777        }
    18021778    }
     
    19651941  static int level = 0;
    19661942
    1967   bool show_it = false;
     1943  int show_it = 0;
    19681944
    19691945  cmt_string temp;
     
    19811957        {
    19821958            // Should not display on recursive calls
    1983           if (level == 0) show_it = m_display_it;
     1959          if (level == 0) show_it = 1;
    19841960        }
    19851961    }
     
    23002276  cmt_string previous_temp;
    23012277  static const cmt_string empty;
    2302   bool show_it = false;
     2278  int show_it = 0;
    23032279
    23042280  ActionType action = Cmt::get_action ();
     
    23092285        {
    23102286             // Should not display on recursive calls
    2311           if (level == 0) show_it = m_display_it;
     2287          if (level == 0) show_it = 1;
    23122288        }
    23132289    }
     
    25462522  cmt_string previous_temp;
    25472523  static const cmt_string empty;
    2548   bool show_it = false;
     2524  int show_it = 0;
    25492525
    25502526  ActionType action = Cmt::get_action ();
     
    25552531        {
    25562532             // Should not display on recursive calls
    2557           if (level == 0) show_it = m_display_it;
     2533          if (level == 0) show_it = 1;
    25582534        }
    25592535    }
     
    28132789}
    28142790
    2815 //-------------------------------------------------------------
    2816 bool Symbol::check_tag_used (Tag* tag)
    2817 {
    2818   if (tag == 0) return (false);
    2819 
    2820   static SymbolVector& Symbols = symbols ();
    2821 
    2822   if (Symbols.size () == 0)
    2823     {
    2824       return (false);
    2825     }
    2826 
    2827   for (int number = 0; number < Symbol::symbol_number (); number++)
    2828     {
    2829       Symbol& symbol = Symbol::symbol (number);
    2830 
    2831       for (int i = 0; i < symbol.value_lists.size (); i++)
    2832         {
    2833           const SymbolValueList& value_list = symbol.value_lists[i];
    2834 
    2835           for (int j = 0; j < value_list.values.size (); j++)
    2836             {
    2837               const SymbolValue& value = value_list.values[j];
    2838               Tag* t = value.tag;
    2839 
    2840               if (t != 0)
    2841                 {
    2842                   if (t->use_operand (tag)) return (true);
    2843                 }
    2844             }
    2845         }
    2846     }
    2847 
    2848   return (false);
    2849 }
    2850 
Note: See TracChangeset for help on using the changeset viewer.