Changeset 136
- Timestamp:
- Jan 9, 2006, 6:55:56 PM (18 years ago)
- Location:
- CMT/HEAD
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
CMT/HEAD/ChangeLog
r135 r136 1 2006-01-09 <arnault@lal.in2p3.fr> 292 2 3 * source/cmt_project.cxx (create_project): Access CMTPROJECTPATH through 4 symbol or getenv 5 6 * source/cmt_symbol.cxx (get_env_value): Make use of the global 7 display inhibitor to ensure that temporary value builder will not 8 show unexpected output. 9 10 * source/cmt_symbol.h (class Symbol): Define a special accessor function for 11 retrieving the value a symbols associated with an env. var. (typically 12 for CMTPATH like variables) 13 14 * source/cmt_symbol.cxx (action): Trigger the Cmt::configure_cmt_path 15 from CMTPROJECTPATH like CMTPATH 16 1 17 2005-10-31 Christian Arnault <arnault@lal.in2p3.fr> 291 2 18 -
CMT/HEAD/mgr/cmt.nmake
r113 r136 3 3 # Application cmt 4 4 # 5 # Generated Sun Oct 30 10:05:41 2005by ARNAULT5 # Generated Mon Jan 09 18:51:50 2006 by ARNAULT 6 6 # 7 7 #==================================== -
CMT/HEAD/source/cmt_parser.cxx
r109 r136 559 559 cmt_string s; 560 560 561 /* 561 562 Symbol* symbol = Symbol::find ("CMTPATH"); 562 563 if (symbol != 0) … … 583 584 s = CmtSystem::getenv ("CMTPATH"); 584 585 } 586 */ 587 588 s = Symbol::get_env_value ("CMTPATH"); 585 589 586 590 { -
CMT/HEAD/source/cmt_project.cxx
r100 r136 204 204 sep = CmtSystem::path_separator (); 205 205 206 cmt_string cmtprojectpath = CmtSystem::getenv("CMTPROJECTPATH");206 cmt_string cmtprojectpath = Symbol::get_env_value ("CMTPROJECTPATH"); 207 207 CmtSystem::cmt_string_vector items; 208 208 CmtSystem::split (cmtprojectpath, sep, items); … … 1427 1427 // + the new project is then parsed ... etc... 1428 1428 1429 cmt_string cmtprojectpath = CmtSystem::getenv ("CMTPROJECTPATH"); 1429 cmt_string cmtprojectpath = Symbol::get_env_value ("CMTPROJECTPATH"); 1430 1430 1431 cmt_string sep; 1431 1432 sep = CmtSystem::path_separator (); -
CMT/HEAD/source/cmt_symbol.cxx
r113 r136 14 14 #include "cmt_system.h" 15 15 #include "cmt_database.h" 16 17 // Global inhibitor of any display 18 bool Symbol::m_inhibit_display = false; 16 19 17 20 //------------------------------------------------------------- … … 981 984 if (Cmt::get_current_access () == UserMode) 982 985 { 986 /* 987 The following statements mean that some symbols are 988 always private. 989 This list is hardcoded. This should be replaced by a 990 database of "private" symbols. 991 */ 983 992 if (name == "constituents") return; 984 993 if (name == "constituentscclean") return; … … 1028 1037 1029 1038 if (name == "CMTPATH") 1039 { 1040 Cmt::configure_cmt_path (use); 1041 } 1042 else if (name == "CMTPROJECTPATH") 1030 1043 { 1031 1044 Cmt::configure_cmt_path (use); … … 1942 1955 SymbolValue& value = value_list.values[selected]; 1943 1956 1944 if (show_it )1957 if (show_it && !Symbol::get_inhibit_display()) 1945 1958 { 1946 1959 value_list.show (symbol, value, first_definition); … … 2148 2161 SymbolValue& value = value_list.values[selected]; 2149 2162 2150 if (show_it )2163 if (show_it && !Symbol::get_inhibit_display()) 2151 2164 { 2152 2165 value_list.show (symbol, value, first_definition); … … 2499 2512 SymbolValue& value = value_list.values[selected]; 2500 2513 2501 if (show_it )2514 if (show_it && !Symbol::get_inhibit_display()) 2502 2515 { 2503 2516 value_list.show (symbol, value, first_definition); … … 2531 2544 SymbolValue& value = value_list.values[selected]; 2532 2545 2533 if (show_it )2546 if (show_it && !Symbol::get_inhibit_display()) 2534 2547 { 2535 2548 value_list.show (symbol, value, first_definition); … … 2592 2605 SymbolValue& value = value_list.values[selected]; 2593 2606 2594 if (show_it )2607 if (show_it && !Symbol::get_inhibit_display()) 2595 2608 { 2596 2609 value_list.show (symbol, value, first_definition); … … 2620 2633 SymbolValue& value = value_list.values[selected]; 2621 2634 2622 if (show_it )2635 if (show_it && !Symbol::get_inhibit_display()) 2623 2636 { 2624 2637 value_list.show (symbol, value, first_definition); … … 2745 2758 SymbolValue& value = value_list.values[selected]; 2746 2759 2747 if (show_it )2760 if (show_it && !Symbol::get_inhibit_display()) 2748 2761 { 2749 2762 value_list.show (symbol, value, first_definition); … … 3011 3024 } 3012 3025 3026 //------------------------------------------------------------- 3027 cmt_string Symbol::get_env_value (const cmt_string& name) 3028 { 3029 cmt_string s; 3030 3031 Symbol* symbol = Symbol::find (name); 3032 if (symbol != 0) 3033 { 3034 m_inhibit_display = true; 3035 3036 s = symbol->build_macro_value (); 3037 Symbol::expand (s); 3038 3039 m_inhibit_display = false; 3040 } 3041 else 3042 { 3043 s = CmtSystem::getenv (name); 3044 } 3045 3046 return (s); 3047 } 3048 3049 bool Symbol::get_inhibit_display () 3050 { 3051 return (m_inhibit_display); 3052 } 3053 -
CMT/HEAD/source/cmt_symbol.h
r102 r136 101 101 static bool check_tag_used (Tag* tag); 102 102 103 static cmt_string get_env_value (const cmt_string& name); 104 105 static bool get_inhibit_display (); 106 103 107 public: 104 108 Symbol (); … … 126 130 127 131 int selected_value; /* according to the last selected tag */ 132 133 private: 134 135 static bool m_inhibit_display; // Global inhibitor of any display 136 128 137 }; 129 138
Note: See TracChangeset
for help on using the changeset viewer.