aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggert2015-10-21 20:10:40 -0700
committerPaul Eggert2015-10-21 20:11:23 -0700
commit0bb27cd32e4a6a7fc4485381efc9ff0026e15689 (patch)
tree4367708145574829e615f3840bbdad923a2343a0
parent2ab48bafa3e8c3c686dcadfb5d2410178e9dd269 (diff)
downloademacs-0bb27cd32e4a6a7fc4485381efc9ff0026e15689.tar.gz
emacs-0bb27cd32e4a6a7fc4485381efc9ff0026e15689.zip
Merge from gnulib
This incorporates: 2015-10-18 stdalign: work around pre-4.9 GCC x86 bug 2015-10-18 time_rz: avoid warning from bleeding-edge gcc's -Wnonnull * doc/misc/texinfo.tex, lib/stdalign.in.h, lib/time_rz.c: Copy from gnulib.
-rw-r--r--doc/misc/texinfo.tex146
-rw-r--r--lib/stdalign.in.h5
-rw-r--r--lib/time_rz.c9
3 files changed, 96 insertions, 64 deletions
diff --git a/doc/misc/texinfo.tex b/doc/misc/texinfo.tex
index 46a9d1535df..c75ddd6e0df 100644
--- a/doc/misc/texinfo.tex
+++ b/doc/misc/texinfo.tex
@@ -3,7 +3,7 @@
3% Load plain if necessary, i.e., if running under initex. 3% Load plain if necessary, i.e., if running under initex.
4\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi 4\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
5% 5%
6\def\texinfoversion{2015-10-09.18} 6\def\texinfoversion{2015-10-17.11}
7% 7%
8% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, 8% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
9% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 9% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
@@ -1106,6 +1106,7 @@ where each line of input produces a line of output.}
1106\newtoks\toksC 1106\newtoks\toksC
1107\newtoks\toksD 1107\newtoks\toksD
1108\newbox\boxA 1108\newbox\boxA
1109\newbox\boxB
1109\newcount\countA 1110\newcount\countA
1110\newif\ifpdf 1111\newif\ifpdf
1111\newif\ifpdfmakepagedest 1112\newif\ifpdfmakepagedest
@@ -4605,6 +4606,8 @@ end
4605} 4606}
4606 4607
4607% \commondummiesnofonts: common to \commondummies and \indexnofonts. 4608% \commondummiesnofonts: common to \commondummies and \indexnofonts.
4609% Define \definedumyletter, \definedummyaccent and \definedummyword before
4610% using.
4608% 4611%
4609\def\commondummiesnofonts{% 4612\def\commondummiesnofonts{%
4610 % Control letters and accents. 4613 % Control letters and accents.
@@ -4700,11 +4703,27 @@ end
4700{ 4703{
4701\catcode`\<=13 4704\catcode`\<=13
4702\catcode`\-=13 4705\catcode`\-=13
4706\catcode`\`=13
4703 \gdef\indexnonalnumdisappear{% 4707 \gdef\indexnonalnumdisappear{%
4704 \backslashdisappear 4708 \expandafter\ifx\csname SETtxiindexlquoteignore\endcsname\relax\else
4705 \def-{}% 4709 % @set txiindexlquoteignore makes us ignore left quotes in the sort term.
4706 \def<{}% 4710 % (Introduced for FSFS 2nd ed.)
4707 \def\@{}% 4711 \let`=\empty
4712 \fi
4713 %
4714 \expandafter\ifx\csname SETtxiindexbackslashignore\endcsname\relax\else
4715 \backslashdisappear
4716 \fi
4717 %
4718 \expandafter\ifx\csname SETtxiindexhyphenignore\endcsname\relax\else
4719 \def-{}%
4720 \fi
4721 \expandafter\ifx\csname SETtxiindexlessthanignore\endcsname\relax\else
4722 \def<{}%
4723 \fi
4724 \expandafter\ifx\csname SETtxiindexatsignignore\endcsname\relax\else
4725 \def\@{}%
4726 \fi
4708 } 4727 }
4709 4728
4710 \gdef\indexnonalnumreappear{% 4729 \gdef\indexnonalnumreappear{%
@@ -4728,7 +4747,6 @@ end
4728 \def\definedummyletter##1{\let##1\empty}% 4747 \def\definedummyletter##1{\let##1\empty}%
4729 % All control words become @asis by default; overrides below. 4748 % All control words become @asis by default; overrides below.
4730 \let\definedummyword\definedummyaccent 4749 \let\definedummyword\definedummyaccent
4731 %
4732 \commondummiesnofonts 4750 \commondummiesnofonts
4733 % 4751 %
4734 % Don't no-op \tt, since it isn't a user-level command 4752 % Don't no-op \tt, since it isn't a user-level command
@@ -4741,8 +4759,6 @@ end
4741 \def\_{\normalunderscore}% 4759 \def\_{\normalunderscore}%
4742 \def\-{}% @- shouldn't affect sorting 4760 \def\-{}% @- shouldn't affect sorting
4743 % 4761 %
4744 % Unfortunately, texindex < 6.0 is not prepared to handle braces in the
4745 % content at all, so these won't be sorted in ASCII order.
4746 \def\lbracechar{{\indexlbrace}}% 4762 \def\lbracechar{{\indexlbrace}}%
4747 \def\rbracechar{{\indexrbrace}}% 4763 \def\rbracechar{{\indexrbrace}}%
4748 \let\{=\lbracechar 4764 \let\{=\lbracechar
@@ -4805,9 +4821,6 @@ end
4805 \def\result{=>}% 4821 \def\result{=>}%
4806 \def\textdegree{o}% 4822 \def\textdegree{o}%
4807 % 4823 %
4808 \expandafter\ifx\csname SETtxiindexlquoteignore\endcsname\relax
4809 \else \indexlquoteignore \fi
4810 %
4811 % We need to get rid of all macros, leaving only the arguments (if present). 4824 % We need to get rid of all macros, leaving only the arguments (if present).
4812 % Of course this is not nearly correct, but it is the best we can do for now. 4825 % Of course this is not nearly correct, but it is the best we can do for now.
4813 % makeinfo does not expand macros in the argument to @deffn, which ends up 4826 % makeinfo does not expand macros in the argument to @deffn, which ends up
@@ -4821,10 +4834,6 @@ end
4821 \macrolist 4834 \macrolist
4822} 4835}
4823 4836
4824% Undocumented (for FSFS 2nd ed.): @set txiindexlquoteignore makes us
4825% ignore left quotes in the sort term.
4826{\catcode`\`=\active
4827 \gdef\indexlquoteignore{\let`=\empty}}
4828 4837
4829\let\SETmarginindex=\relax % put index entries in margin (undocumented)? 4838\let\SETmarginindex=\relax % put index entries in margin (undocumented)?
4830 4839
@@ -4917,9 +4926,9 @@ end
4917 % Get the string to sort by, by processing the index entry with all 4926 % Get the string to sort by, by processing the index entry with all
4918 % font commands turned off. 4927 % font commands turned off.
4919 {\indexnofonts 4928 {\indexnofonts
4929 \indexnonalnumdisappear
4920 \xdef\indexsortkey{}% 4930 \xdef\indexsortkey{}%
4921 \let\sortas=\indexwritesortas 4931 \let\sortas=\indexwritesortas
4922 \indexnonalnumdisappear
4923 \edef\temp{\the\toks0}% 4932 \edef\temp{\the\toks0}%
4924 \setbox\dummybox = \hbox{\temp}% Make sure to execute any \sortas 4933 \setbox\dummybox = \hbox{\temp}% Make sure to execute any \sortas
4925 \ifx\indexsortkey\empty 4934 \ifx\indexsortkey\empty
@@ -5214,30 +5223,6 @@ end
5214 % How much \indexdotfill is stretched, or how much \parfillskip is shrunk 5223 % How much \indexdotfill is stretched, or how much \parfillskip is shrunk
5215 % Number of lines (\linepenalty) 5224 % Number of lines (\linepenalty)
5216 % 5225 %
5217 % Do not prefer a separate line ending with a hyphen to fewer lines.
5218 \finalhyphendemerits = 0
5219 %
5220 % Word spacing - no stretch
5221 \spaceskip=\fontdimen2\font minus \fontdimen4\font
5222 %
5223 \linepenalty=1000 % Discourage line breaks.
5224 \hyphenpenalty=5000 % Discourage hyphenation.
5225 %
5226 % Ragged right margin, but not for the last line with the leaders in it.
5227 % When an index entry spans lines, this stretch competes with the stretch
5228 % in \indexdotfill to determine how the line will be split.
5229 \rightskip=\entryrightmargin
5230 \advance\rightskip by 0pt plus .6\hsize
5231 %
5232 % \parfillskip is at the end of the line with the page number
5233 \parfillskip=0pt
5234 % Cancel the \rightskip stretch
5235 \advance \parfillskip by 0pt plus -.6\hsize
5236 % Determine how far we can stretch into the margin.
5237 % This allows, e.g., "Appendix H GNU Free Documentation License" to fit
5238 % on one line.
5239 \advance \parfillskip by 0pt minus .6\entryrightmargin
5240 %
5241 % Swallow the left brace of the text (first parameter): 5226 % Swallow the left brace of the text (first parameter):
5242 \afterassignment\doentry 5227 \afterassignment\doentry
5243 \let\temp = 5228 \let\temp =
@@ -5245,20 +5230,26 @@ end
5245\def\entrybreak{\unskip\space\ignorespaces}% 5230\def\entrybreak{\unskip\space\ignorespaces}%
5246\def\doentry{% 5231\def\doentry{%
5247 % Save the text of the entry in a \vtop. 5232 % Save the text of the entry in a \vtop.
5248 \global\setbox\entryindexbox=\vtop\bgroup 5233 \global\setbox\boxA=\hbox\bgroup
5249 \bgroup % Instead of the swallowed brace. 5234 \bgroup % Instead of the swallowed brace.
5250 \noindent 5235 \noindent
5251 \aftergroup\finishentry 5236 \aftergroup\finishentry
5252 % And now comes the text of the entry. 5237 % And now comes the text of the entry.
5238 % Not absorbing as a macro argument reduces the chance of problems
5239 % with catcodes occurring.
5253} 5240}
5254\def\finishentry#1{% 5241{\catcode`\@=11
5242\gdef\finishentry#1{%
5243 \egroup % end box A
5244 \dimen@ = \wd\boxA % Length of text of entry
5245 \global\setbox\boxA=\hbox\bgroup\unhbox\boxA
5255 % #1 is the page number. 5246 % #1 is the page number.
5256 % 5247 %
5257 % The following is kludged to not output a line of dots in the index if 5248 % The following is kludged to not output a line of dots in the index if
5258 % there are no page numbers. The next person who breaks this will be 5249 % there are no page numbers. The next person who breaks this will be
5259 % cursed by a Unix daemon. 5250 % cursed by a Unix daemon.
5260 \setbox\boxA = \hbox{#1}% 5251 \setbox\boxB = \hbox{#1}%
5261 \ifdim\wd\boxA = 0pt 5252 \ifdim\wd\boxB = 0pt
5262 \null\nobreak\hfill\ % 5253 \null\nobreak\hfill\ %
5263 \else 5254 \else
5264 % 5255 %
@@ -5271,23 +5262,62 @@ end
5271 \hskip\skip\thinshrinkable #1% 5262 \hskip\skip\thinshrinkable #1%
5272 \fi 5263 \fi
5273 \fi 5264 \fi
5274 % Parameters for formatting this paragraph, reset for each paragraph. 5265 \egroup % end \boxA
5266 \global\setbox\entryindexbox=\vtop\bgroup\noindent
5267 % We want the text of the entries to be aligned to the left, and the
5268 % page numbers to be aligned to the right.
5275 % 5269 %
5276 % \hangindent is only relevant when the entry text and page number 5270 \advance\leftskip by 0pt plus 1fil
5277 % don't both fit on one line. In that case, bob suggests starting the 5271 \advance\leftskip by 0pt plus -1fill
5278 % dots pretty far over on the line. Unfortunately, a large 5272 \rightskip = 0pt plus -1fil
5279 % indentation looks wrong when the entry text itself is broken across 5273 \advance\rightskip by 0pt plus 1fill
5280 % lines. So we use a small indentation and put up with long leaders. 5274 % Cause last line, which could consist of page numbers on their own if the
5275 % list of page numbers is long, to be aligned to the right.
5276 \parfillskip=0pt plus -1fill
5281 % 5277 %
5282 \hangafter = 1 5278 \hangindent=1em
5283 \hangindent = 1em 5279 %
5284 \par 5280 \advance\rightskip by \entryrightmargin
5281 % Determine how far we can stretch into the margin.
5282 % This allows, e.g., "Appendix H GNU Free Documentation License" to fit
5283 % on one line.
5284 \advance \parfillskip by 0pt minus .6\entryrightmargin
5285 %
5286 \ifdim\wd\boxA > \hsize % If the entry doesn't fit in one line
5287 \ifdim\dimen@ > 0.9\hsize % due to long index text
5288 \dimen@ = 0.6\dimen@ % Try to split the text roughly evenly
5289 \dimen@ii = \hsize
5290 \advance \dimen@ii by -1em
5291 \ifnum\dimen@>\dimen@ii
5292 % If the entry is too long, use the whole line
5293 \dimen@ = \dimen@ii
5294 \else
5295 % Cause stretch of 1fill at the end of the first line, to avoid
5296 % extra spacing in a short first line.
5297 \hskip 0pt plus 1fill
5298 \fi
5299 \parshape = 2 0pt \dimen@ 1em \dimen@ii
5300 % Ideally we'd add a finite glue at the end of the first line only, but
5301 % TeX doesn't seem to provide a way to do such a thing.
5302 \fi\fi
5303 \unhbox\boxA
5304 %
5305 % Do not prefer a separate line ending with a hyphen to fewer lines.
5306 \finalhyphendemerits = 0
5307 %
5308 % Word spacing - no stretch
5309 \spaceskip=\fontdimen2\font minus \fontdimen4\font
5310 %
5311 \linepenalty=1000 % Discourage line breaks.
5312 \hyphenpenalty=10000 % Discourage hyphenation.
5313 %
5314 \par % format the paragraph
5285 \egroup % The \vtop 5315 \egroup % The \vtop
5286 \endgroup 5316 \endgroup
5287 % delay text of entry until after penalty 5317 % delay text of entry until after penalty
5288 \bgroup\aftergroup\insertindexentrybox 5318 \bgroup\aftergroup\insertindexentrybox
5289 \entryorphanpenalty 5319 \entryorphanpenalty
5290} 5320}}
5291 5321
5292\newskip\thinshrinkable 5322\newskip\thinshrinkable
5293\skip\thinshrinkable=.15em minus .15em 5323\skip\thinshrinkable=.15em minus .15em
@@ -5322,10 +5352,11 @@ end
5322} 5352}
5323 5353
5324% Like plain.tex's \dotfill, except uses up at least 1 em. 5354% Like plain.tex's \dotfill, except uses up at least 1 em.
5325% Using a finite stretch encourages several words to appear on a second line 5355% The filll stretch here overpowers both the fil and fill stretch to push
5326% if the entry is broken. 5356% the page number to the right.
5327\def\indexdotfill{\cleaders 5357\def\indexdotfill{\cleaders
5328 \hbox{$\mathsurround=0pt \mkern1.5mu.\mkern1.5mu$}\hskip 1em plus .4\hsize} 5358 \hbox{$\mathsurround=0pt \mkern1.5mu.\mkern1.5mu$}\hskip 1em plus 1filll}
5359
5329 5360
5330\def\primary #1{\line{#1\hfil}} 5361\def\primary #1{\line{#1\hfil}}
5331 5362
@@ -8945,6 +8976,7 @@ end
8945\def\imagexxx#1,#2,#3,#4,#5,#6\finish{\begingroup 8976\def\imagexxx#1,#2,#3,#4,#5,#6\finish{\begingroup
8946 \catcode`\^^M = 5 % in case we're inside an example 8977 \catcode`\^^M = 5 % in case we're inside an example
8947 \normalturnoffactive % allow _ et al. in names 8978 \normalturnoffactive % allow _ et al. in names
8979 \def\xprocessmacroarg{\eatspaces}% in case we are being used via a macro
8948 % If the image is by itself, center it. 8980 % If the image is by itself, center it.
8949 \ifvmode 8981 \ifvmode
8950 \imagevmodetrue 8982 \imagevmodetrue
diff --git a/lib/stdalign.in.h b/lib/stdalign.in.h
index c6115b6dbe0..ce1e793e273 100644
--- a/lib/stdalign.in.h
+++ b/lib/stdalign.in.h
@@ -52,7 +52,10 @@
52#undef _Alignas 52#undef _Alignas
53#undef _Alignof 53#undef _Alignof
54 54
55#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112 55/* GCC releases before GCC 4.9 had a bug in _Alignof. See GCC bug 52023
56 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
57#if (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112 \
58 || (defined __GNUC__ && __GNUC__ < 4 + (__GNUC_MINOR__ < 9)))
56# ifdef __cplusplus 59# ifdef __cplusplus
57# if 201103 <= __cplusplus 60# if 201103 <= __cplusplus
58# define _Alignof(type) alignof (type) 61# define _Alignof(type) alignof (type)
diff --git a/lib/time_rz.c b/lib/time_rz.c
index f94893aa2c1..a89b7e70f14 100644
--- a/lib/time_rz.c
+++ b/lib/time_rz.c
@@ -90,8 +90,7 @@ extend_abbrs (char *abbrs, char const *abbr, size_t abbr_size)
90} 90}
91 91
92/* Return a newly allocated time zone for NAME, or NULL on failure. 92/* Return a newly allocated time zone for NAME, or NULL on failure.
93 As a special case, return a nonzero constant for wall clock time, a 93 A null NAME stands for wall clock time (which is like unset TZ). */
94 constant that survives freeing. */
95timezone_t 94timezone_t
96tzalloc (char const *name) 95tzalloc (char const *name)
97{ 96{
@@ -288,10 +287,8 @@ localtime_rz (timezone_t tz, time_t const *t, struct tm *tm)
288 timezone_t old_tz = set_tz (tz); 287 timezone_t old_tz = set_tz (tz);
289 if (old_tz) 288 if (old_tz)
290 { 289 {
291 tm = localtime_r (t, tm); 290 bool abbr_saved = localtime_r (t, tm) && save_abbr (tz, tm);
292 if (tm && !save_abbr (tz, tm)) 291 if (revert_tz (old_tz) && abbr_saved)
293 tm = NULL;
294 if (revert_tz (old_tz))
295 return tm; 292 return tm;
296 } 293 }
297 return NULL; 294 return NULL;