diff src/symtab.cc @ 3523:b80bbb43a1a9

[project @ 2000-02-02 10:25:52 by jwe]
author jwe
date Wed, 02 Feb 2000 10:26:25 +0000
parents d14c483b3c12
children 096ad38d7ab5
line wrap: on
line diff
--- a/src/symtab.cc	Wed Feb 02 06:32:04 2000 +0000
+++ b/src/symtab.cc	Wed Feb 02 10:26:25 2000 +0000
@@ -61,7 +61,7 @@
 string
 SYMBOL_DEF::type_as_string (void) const
 {
-  string retval = "<unknown type>";
+  std::string retval = "<unknown type>";
 
   if (is_user_variable ())
     retval = "user-defined variable";
@@ -84,18 +84,18 @@
 }
 
 void
-SYMBOL_DEF::type (ostream& os, const string& name, bool pr_type_info,
+SYMBOL_DEF::type (std::ostream& os, const std::string& name, bool pr_type_info,
 		  bool quiet, bool pr_orig_txt)
 {
   if (is_user_function ())
     {
       octave_function *defn = definition.function_value ();
 
-      string fn = defn ? defn->fcn_file_name () : string ();
+      std::string fn = defn ? defn->fcn_file_name () : std::string ();
 
       if (pr_orig_txt && ! fn.empty ())
 	{
-	  ifstream fs (fn.c_str (), ios::in);
+	  std::ifstream fs (fn.c_str (), ios::in);
 
 	  if (fs)
 	    {
@@ -138,9 +138,9 @@
 }
 
 string
-SYMBOL_DEF::which (const string& name)
+SYMBOL_DEF::which (const std::string& name)
 {
-  string retval;
+  std::string retval;
 
   if (is_user_function () || is_dld_function ())
     {
@@ -156,7 +156,7 @@
 }
 
 void
-SYMBOL_DEF::which (ostream& os, const string& name)
+SYMBOL_DEF::which (std::ostream& os, const std::string& name)
 {
   os << name;
 
@@ -164,7 +164,7 @@
     {
       octave_function *defn = definition.function_value ();
 
-      string fn = defn ? defn->fcn_file_name () : string ();
+      std::string fn = defn ? defn->fcn_file_name () : std::string ();
 
       if (! fn.empty ())
 	{
@@ -192,7 +192,7 @@
 // probably be temporarily ignoring interrupts.
 
 void
-symbol_record::rename (const string& new_name)
+symbol_record::rename (const std::string& new_name)
 {
   if (! read_only_error ("rename"))
     nm = new_name;
@@ -445,7 +445,7 @@
 }
 
 void
-symbol_record::print_symbol_info_line (ostream& os)
+symbol_record::print_symbol_info_line (std::ostream& os)
 {
   os << (is_read_only () ? " r-" : " rw")
      << (is_eternal () ? "-" : "d")
@@ -541,7 +541,7 @@
 // A symbol table.
 
 symbol_record *
-symbol_table::lookup (const string& nm, bool insert, bool warn)
+symbol_table::lookup (const std::string& nm, bool insert, bool warn)
 {
   unsigned int index = hash (nm);
 
@@ -570,7 +570,7 @@
 }
 
 void
-symbol_table::rename (const string& old_name, const string& new_name)
+symbol_table::rename (const std::string& old_name, const std::string& new_name)
 {
   unsigned int index = hash (old_name);
 
@@ -627,7 +627,7 @@
 }
 
 bool
-symbol_table::clear (const string& nm, bool clear_user_functions)
+symbol_table::clear (const std::string& nm, bool clear_user_functions)
 {
   unsigned int index = hash (nm);
 
@@ -669,7 +669,7 @@
 }
 
 static bool
-matches_patterns (const string& name, const string_vector& pats)
+matches_patterns (const std::string& name, const string_vector& pats)
 {
   int npats = pats.length ();
 
@@ -706,7 +706,7 @@
 
 	  unsigned int my_type = ptr->type ();
 
-	  string my_name = ptr->name ();
+	  std::string my_name = ptr->name ();
 
 	  if ((type & my_type) && (scope & my_scope)
 	      && matches_patterns (my_name, pats))
@@ -751,15 +751,15 @@
   const symbol_record *a = *(X_CAST (const symbol_record **, a_arg));
   const symbol_record *b = *(X_CAST (const symbol_record **, b_arg));
 
-  string a_nm = a->name ();
-  string b_nm = b->name ();
+  std::string a_nm = a->name ();
+  std::string b_nm = b->name ();
 
   return a_nm.compare (b_nm);
 }
 
 int
 symbol_table::maybe_list (const char *header, const string_vector& argv,
-			  ostream& os, bool show_verbose,
+			  std::ostream& os, bool show_verbose,
 			  unsigned type, unsigned scope)
 {
   int status = 0;
@@ -802,7 +802,7 @@
 }
 
 Array<symbol_record *>
-symbol_table::glob (const string& pat, unsigned int type,
+symbol_table::glob (const std::string& pat, unsigned int type,
 		    unsigned int scope) const
 {
   int count = 0;
@@ -926,7 +926,7 @@
 // Chris Torek's fave hash function.
 
 unsigned int
-symbol_table::hash (const string& str)
+symbol_table::hash (const std::string& str)
 {
   unsigned int h = 0;