2008-10-03 H.J. Lu <hongjiu.lu@intel.com>
[deliverable/binutils-gdb.git] / gdb / stabsread.c
index 110f9373b3477c5e9e71611ffccbe1f838c1e0de..45e7cee1211468280c323731722eaf940b10ec13 100644 (file)
@@ -684,6 +684,8 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
     normal:
       SYMBOL_LANGUAGE (sym) = current_subfile->language;
       SYMBOL_SET_NAMES (sym, string, p - string, objfile);
+      if (SYMBOL_LANGUAGE (sym) == language_cplus)
+       cp_scan_for_anonymous_namespaces (sym);
     }
   p++;
 
@@ -824,7 +826,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
          than the "declared-as" type for unprototyped functions, so
          we treat all functions as if they were prototyped.  This is used
          primarily for promotion when calling the function from GDB.  */
-      TYPE_FLAGS (SYMBOL_TYPE (sym)) |= TYPE_FLAG_PROTOTYPED;
+      TYPE_PROTOTYPED (SYMBOL_TYPE (sym)) = 1;
 
       /* fall into process_prototype_types */
 
@@ -870,7 +872,7 @@ define_symbol (CORE_ADDR valu, char *string, int desc, int type,
              TYPE_FIELD_ARTIFICIAL (ftype, nparams++) = 0;
            }
          TYPE_NFIELDS (ftype) = nparams;
-         TYPE_FLAGS (ftype) |= TYPE_FLAG_PROTOTYPED;
+         TYPE_PROTOTYPED (ftype) = 1;
        }
       break;
 
@@ -1562,7 +1564,7 @@ again:
        TYPE_CODE (type) = code;
        TYPE_TAG_NAME (type) = type_name;
        INIT_CPLUS_SPECIFIC (type);
-       TYPE_FLAGS (type) |= TYPE_FLAG_STUB;
+       TYPE_STUB (type) = 1;
 
        add_undefined_type (type, typenums);
        return type;
@@ -1628,7 +1630,7 @@ again:
          }
        else
          {
-           TYPE_FLAGS (type) |= TYPE_FLAG_TARGET_STUB;
+           TYPE_TARGET_STUB (type) = 1;
            TYPE_TARGET_TYPE (type) = xtype;
          }
       }
@@ -1723,7 +1725,7 @@ again:
             TYPE_FIELD_TYPE (func_type, i) = t->type;
         }
         TYPE_NFIELDS (func_type) = num_args;
-        TYPE_FLAGS (func_type) |= TYPE_FLAG_PROTOTYPED;
+        TYPE_PROTOTYPED (func_type) = 1;
 
         type = func_type;
         break;
@@ -3336,7 +3338,7 @@ read_struct_type (char **pp, struct type *type, enum type_code type_code,
 
   INIT_CPLUS_SPECIFIC (type);
   TYPE_CODE (type) = type_code;
-  TYPE_FLAGS (type) &= ~TYPE_FLAG_STUB;
+  TYPE_STUB (type) = 0;
 
   /* First comes the total size in bytes.  */
 
@@ -3510,9 +3512,9 @@ read_enum_type (char **pp, struct type *type,
 
   TYPE_LENGTH (type) = gdbarch_int_bit (gdbarch) / HOST_CHAR_BIT;
   TYPE_CODE (type) = TYPE_CODE_ENUM;
-  TYPE_FLAGS (type) &= ~TYPE_FLAG_STUB;
+  TYPE_STUB (type) = 0;
   if (unsigned_enum)
-    TYPE_FLAGS (type) |= TYPE_FLAG_UNSIGNED;
+    TYPE_UNSIGNED (type) = 1;
   TYPE_NFIELDS (type) = nsyms;
   TYPE_FIELDS (type) = (struct field *)
     TYPE_ALLOC (type, sizeof (struct field) * nsyms);
This page took 0.028365 seconds and 4 git commands to generate.