gdb: Update comments that reference VEC or vec.h
authorAndrew Burgess <andrew.burgess@embecosm.com>
Mon, 7 Oct 2019 15:45:24 +0000 (16:45 +0100)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Tue, 15 Oct 2019 20:32:28 +0000 (21:32 +0100)
With the removal of the old VEC mechanism from the code base, update
comments that still make reference to VECs.  There should be no user
visible changes after this commit.

gdb/ChangeLog:

* linespec.c (decode_digits_ordinary): Update comment.
* make-target-delegates: No longer need to handle VEC case.
* memrange.c (normalize_mem_ranges): Update comment.
* namespace.c (add_using_directive): Update comment.
* objc-lang.c (uniquify_strings): Update comment.
* ppc-linux-nat.c (struct thread_points): Update comment.
* probe.h (find_probes_in_objfile): Update comment.
* target.h (enum flash_preserve_mode): Update comment.
* varobj.c (varobj_restrict_range): Update comment.
* varobj.h (varobj_list_children): Update comment.

Change-Id: Iefd2e903705c3e79cd13b43395c7a1c167f9a088

gdb/ChangeLog
gdb/linespec.c
gdb/make-target-delegates
gdb/memrange.c
gdb/namespace.c
gdb/objc-lang.c
gdb/ppc-linux-nat.c
gdb/probe.h
gdb/target.h
gdb/varobj.c
gdb/varobj.h

index 8328a9b3c875aefddfd074f56ceb58cb6ef68e5a..3827c4d3235a749708622975a55b6ae571d5e6b1 100644 (file)
@@ -1,3 +1,16 @@
+2019-10-15  Andrew Burgess  <andrew.burgess@embecosm.com>
+
+       * linespec.c (decode_digits_ordinary): Update comment.
+       * make-target-delegates: No longer need to handle VEC case.
+       * memrange.c (normalize_mem_ranges): Update comment.
+       * namespace.c (add_using_directive): Update comment.
+       * objc-lang.c (uniquify_strings): Update comment.
+       * ppc-linux-nat.c (struct thread_points): Update comment.
+       * probe.h (find_probes_in_objfile): Update comment.
+       * target.h (enum flash_preserve_mode): Update comment.
+       * varobj.c (varobj_restrict_range): Update comment.
+       * varobj.h (varobj_list_children): Update comment.
+
 2019-10-15  Andrew Burgess  <andrew.burgess@embecosm.com>
 
        * Makefile.in: Remove references to vec.h and vec.c.
index ac7d34dfe96f898e74a534fad79324a3a6004932..fb6b04e22b008f28426936d5411f81827562c674 100644 (file)
@@ -4109,8 +4109,9 @@ decode_digits_list_mode (struct linespec_state *self,
   return values;
 }
 
-/* A helper for create_sals_line_offset that iterates over the symtabs,
-   adding lines to the VEC.  */
+/* A helper for create_sals_line_offset that iterates over the symtabs
+   associated with LS and returns a vector of corresponding symtab_and_line
+   structures.  */
 
 static std::vector<symtab_and_line>
 decode_digits_ordinary (struct linespec_state *self,
index 329306d7f25bc4d322b6690d16269965840b8213..a7a39b3289726ea95301b19b2d87896cb468c9af 100755 (executable)
@@ -43,11 +43,9 @@ $POINTER_PART = qr,\s*(\*)?\s*,;
 $CP_SYMBOL = qr,[a-zA-Z_][a-zA-Z0-9_<>:]*,;
 # Match the return type when it is "ordinary".
 $SIMPLE_RETURN_PART = qr,((struct|class|enum|union)\s+)?${CP_SYMBOL}+,;
-# Match the return type when it is a VEC.
-$VEC_RETURN_PART = qr,VEC\s*\([^\)]+\),;
 
 # Match a return type.
-$RETURN_PART = qr,((const|volatile)\s+)?(${SIMPLE_RETURN_PART}|${VEC_RETURN_PART})${POINTER_PART},;
+$RETURN_PART = qr,((const|volatile)\s+)?(${SIMPLE_RETURN_PART})${POINTER_PART},;
 
 # Match "virtual".
 $VIRTUAL_PART = qr,virtual\s,;
index 0f999815c542a61afae9498e534fed0617735cfc..0c4b41582955315282e1204cd4db0508c5a4b974 100644 (file)
@@ -44,10 +44,6 @@ address_in_mem_range (CORE_ADDR address, const struct mem_range *r)
 void
 normalize_mem_ranges (std::vector<mem_range> *memory)
 {
-  /* This function must not use any VEC operation on RANGES that
-     reallocates the memory block as that invalidates the RANGES
-     pointer, which callers expect to remain valid.  */
-
   if (!memory->empty ())
     {
       std::vector<mem_range> &m = *memory;
index 04b49ef0e34abca53e46552f14443f86101cf160..e08d4f7edb4e6bc710a04f970295e7cbfa872837 100644 (file)
@@ -30,8 +30,8 @@
    it is NULL.  EXCLUDES is a list of names not to import from an
    imported module or NULL.  If COPY_NAMES is non-zero, then the
    arguments are copied into newly allocated memory so they can be
-   temporaries.  For EXCLUDES the VEC pointers are copied but the
-   pointed to characters are not copied.  */
+   temporaries.  For EXCLUDES the contents of the vector are copied,
+   but the pointed to characters are not copied.  */
 
 void
 add_using_directive (struct using_direct **using_directives,
index ab40e54a169403de23389ce8f866f245d6d15334..fbf0dab2ae233b83ed3769f4320b289309ec4126 100644 (file)
@@ -1063,7 +1063,7 @@ find_methods (char type, const char *theclass, const char *category,
     }
 }
 
-/* Uniquify a VEC of strings.  */
+/* Uniquify a vector of strings.  */
 
 static void
 uniquify_strings (std::vector<const char *> *strings)
index 53406f61c8ed806c926503b8c56e44ea492577f2..0d66ade45606302937df77cefde76dbb5ed76a12 100644 (file)
@@ -1575,9 +1575,9 @@ struct hw_break_tuple
   struct ppc_hw_breakpoint *hw_break;
 };
 
-/* This is an internal VEC created to store information about *points inserted
-   for each thread.  This is used when PowerPC HWDEBUG ptrace interface is
-   available.  */
+/* This is an internal vector created to store information about *points
+   inserted for each thread.  This is used when PowerPC HWDEBUG ptrace
+   interface is available.  */
 struct thread_points
   {
     /* The TID to which this *point relates.  */
index 7410c5aadf69329c6af4cded5ee952f93a04d989..4227bd43778604582b3272171a24c3a462a54f16 100644 (file)
@@ -274,7 +274,7 @@ extern std::vector<symtab_and_line> parse_probes
 extern struct bound_probe find_probe_by_pc (CORE_ADDR pc);
 
 /* Search OBJFILE for a probe with the given PROVIDER, NAME.  Return a
-   VEC of all probes that were found.  If no matching probe is found,
+   vector of all probes that were found.  If no matching probe is found,
    return an empty vector.  */
 
 extern std::vector<probe *> find_probes_in_objfile (struct objfile *objfile,
index 91e8a837ab27e4dd056876c484c3814564d122f4..1bb72766737ff30fb0d6bb97275b70e6390142c1 100644 (file)
@@ -1535,7 +1535,7 @@ enum flash_preserve_mode
    that supports writing to flash memory, and it should be used for
    all cases where access to flash memory is desirable.
 
-   REQUESTS is the vector (see vec.h) of memory_write_request.
+   REQUESTS is the vector of memory_write_request.
    PRESERVE_FLASH_P indicates what to do with blocks which must be
      erased, but not completely rewritten.
    PROGRESS_CB is a function that will be periodically called to provide
index 6265b2fa1722b883bc8e21ee15b603b5ec7315b4..37a522be5d0def661f6e773bd537a687fa7eeb9a 100644 (file)
@@ -597,10 +597,9 @@ varobj_get_frozen (const struct varobj *var)
   return var->frozen;
 }
 
-/* A helper function that restricts a range to what is actually
-   available in a VEC.  This follows the usual rules for the meaning
-   of FROM and TO -- if either is negative, the entire range is
-   used.  */
+/* A helper function that updates the contents of FROM and TO based on the
+   size of the vector CHILDREN.  If the contents of either FROM or TO are
+   negative the entire range is used.  */
 
 void
 varobj_restrict_range (const std::vector<varobj *> &children,
index eb01da10e2d9b169f8b02612af9e2c0cebbcdc93..66db7807fe0eaebb6519bbd320a5b6f295ecfe7c 100644 (file)
@@ -286,7 +286,7 @@ extern int varobj_get_num_children (struct varobj *var);
    indicating the range of children to return.  If either *FROM or *TO
    is less than zero on entry, then all children will be returned.  On
    return, *FROM and *TO will be updated to indicate the real range
-   that was returned.  The resulting VEC will contain at least the
+   that was returned.  The resulting vector will contain at least the
    children from *FROM to just before *TO; it might contain more
    children, depending on whether any more were available.  */
 extern const std::vector<varobj *> &
This page took 0.034996 seconds and 4 git commands to generate.