This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v2 02/16] change how list of modules is computed


On 11/06/2013 05:09 PM, Tom Tromey wrote:
> While adding modules I found that the current approach of listing all
> the modules on one line made it harder to experiment -- any conflicts
> from git were a pain to resolve.
> 
> This patch splits the list of modules so that there is one module per
> line.
> 
> 2013-11-06  Tom Tromey  <tromey@redhat.com>
> 
> 	* gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Split into
> 	multiple lines.
> ---
>  gdb/ChangeLog               | 5 +++++
>  gdb/gnulib/update-gnulib.sh | 9 ++++++++-
>  2 files changed, 13 insertions(+), 1 deletion(-)
> 
> diff --git a/gdb/gnulib/update-gnulib.sh b/gdb/gnulib/update-gnulib.sh
> index 0b292ba..3a8502c 100644
> --- a/gdb/gnulib/update-gnulib.sh
> +++ b/gdb/gnulib/update-gnulib.sh
> @@ -29,7 +29,14 @@
>  #     regenerate the various scripts and Makefiles are on the PATH.
>  
>  # The list of gnulib modules we are importing in GDB.
> -IMPORTED_GNULIB_MODULES="fnmatch-gnu frexpl inttypes memmem update-copyright unistd pathmax"
> +IMPORTED_GNULIB_MODULES=""
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES fnmatch-gnu"
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES frexpl"
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES inttypes"
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES memmem"
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES update-copyright"
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES unistd"
> +IMPORTED_GNULIB_MODULES="$IMPORTED_GNULIB_MODULES pathmax"
>  

Wouldn't using continuation lines work just as well?

-IMPORTED_GNULIB_MODULES="fnmatch-gnu frexpl inttypes memmem update-copyright unistd pathmax"
+IMPORTED_GNULIB_MODULES="\
+  fnmatch-gnu \
+  frexpl \
+  inttypes \
+  memmem \
+  update-copyright \
+  unistd \
+  pathmax \
+"

I'd find that a lot less distracting, therefore more readable.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]