Changes in CMT/v1r19/source/cmt_symbol.cxx [3:1]
- File:
-
- 1 edited
-
CMT/v1r19/source/cmt_symbol.cxx (modified) (13 diffs)
Legend:
- Unmodified
- Added
- Removed
-
CMT/v1r19/source/cmt_symbol.cxx
r3 r1 1541 1541 case Sh : 1542 1542 cout << "alias " << name << 1543 "=\"" << temp << "\""; 1543 "=\"" << temp << 1544 "\"; export " << name; 1544 1545 result = 1; 1545 1546 break; … … 1589 1590 1590 1591 //------------------------------------------------------------- 1591 cmt_string Symbol::build_macro_value ( bool display_it) const1592 cmt_string Symbol::build_macro_value () const 1592 1593 { 1593 1594 cmt_string temp; 1594 1595 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); 1603 1597 1604 1598 return (temp); … … 1658 1652 ActionType action = Cmt::get_action (); 1659 1653 1660 cmt_string value = build_macro_value ( true);1654 cmt_string value = build_macro_value (); 1661 1655 1662 1656 if ((!Cmt::get_quiet ()) && … … 1760 1754 1761 1755 //------------------------------------------------------------- 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 //-------------------------------------------------------------1780 1756 const cmt_string SetBuilder::build (const Symbol& symbol, 1781 1757 const cmt_string& /*tag_name*/) … … 1784 1760 static int level = 0; 1785 1761 1786 bool show_it = false;1762 int show_it = 0; 1787 1763 1788 1764 cmt_string temp; … … 1798 1774 { 1799 1775 // Should not display on recursive calls 1800 if (level == 0) show_it = m_display_it;1776 if (level == 0) show_it = 1; 1801 1777 } 1802 1778 } … … 1965 1941 static int level = 0; 1966 1942 1967 bool show_it = false;1943 int show_it = 0; 1968 1944 1969 1945 cmt_string temp; … … 1981 1957 { 1982 1958 // Should not display on recursive calls 1983 if (level == 0) show_it = m_display_it;1959 if (level == 0) show_it = 1; 1984 1960 } 1985 1961 } … … 2300 2276 cmt_string previous_temp; 2301 2277 static const cmt_string empty; 2302 bool show_it = false;2278 int show_it = 0; 2303 2279 2304 2280 ActionType action = Cmt::get_action (); … … 2309 2285 { 2310 2286 // Should not display on recursive calls 2311 if (level == 0) show_it = m_display_it;2287 if (level == 0) show_it = 1; 2312 2288 } 2313 2289 } … … 2546 2522 cmt_string previous_temp; 2547 2523 static const cmt_string empty; 2548 bool show_it = false;2524 int show_it = 0; 2549 2525 2550 2526 ActionType action = Cmt::get_action (); … … 2555 2531 { 2556 2532 // Should not display on recursive calls 2557 if (level == 0) show_it = m_display_it;2533 if (level == 0) show_it = 1; 2558 2534 } 2559 2535 } … … 2813 2789 } 2814 2790 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.
