(root)/
texinfo-7.1/
tp/
Texinfo/
XS/
XSParagraph.c
       1  /*
       2   * This file was generated automatically by ExtUtils::ParseXS version 3.40 from the
       3   * contents of XSParagraph.xs. Do not edit this file, edit XSParagraph.xs instead.
       4   *
       5   *    ANY CHANGES MADE HERE WILL BE LOST!
       6   *
       7   */
       8  
       9  #line 1 "XSParagraph.xs"
      10  /* Copyright 2010-2023 Free Software Foundation, Inc.
      11  
      12     This program is free software: you can redistribute it and/or modify
      13     it under the terms of the GNU General Public License as published by
      14     the Free Software Foundation, either version 3 of the License, or
      15     (at your option) any later version.
      16  
      17     This program is distributed in the hope that it will be useful,
      18     but WITHOUT ANY WARRANTY; without even the implied warranty of
      19     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      20     GNU General Public License for more details.
      21  
      22     You should have received a copy of the GNU General Public License
      23     along with this program.  If not, see <http://www.gnu.org/licenses/>. */
      24  
      25  #ifdef HAVE_CONFIG_H
      26    #include <config.h>
      27  #endif
      28  
      29  #define PERL_NO_GET_CONTEXT
      30  #include "EXTERN.h"
      31  #include "perl.h"
      32  /* Avoid warnings about Perl headers redefining symbols that gnulib
      33     redefined already. */
      34  #if defined _WIN32 && !defined __CYGWIN__
      35    #undef free
      36  #endif
      37  #include "XSUB.h"
      38  
      39  #include "ppport.h"
      40  
      41  #include "xspara.h"
      42  
      43  #line 44 "XSParagraph.c"
      44  #ifndef PERL_UNUSED_VAR
      45  #  define PERL_UNUSED_VAR(var) if (0) var = var
      46  #endif
      47  
      48  #ifndef dVAR
      49  #  define dVAR		dNOOP
      50  #endif
      51  
      52  
      53  /* This stuff is not part of the API! You have been warned. */
      54  #ifndef PERL_VERSION_DECIMAL
      55  #  define PERL_VERSION_DECIMAL(r,v,s) (r*1000000 + v*1000 + s)
      56  #endif
      57  #ifndef PERL_DECIMAL_VERSION
      58  #  define PERL_DECIMAL_VERSION \
      59  	  PERL_VERSION_DECIMAL(PERL_REVISION,PERL_VERSION,PERL_SUBVERSION)
      60  #endif
      61  #ifndef PERL_VERSION_GE
      62  #  define PERL_VERSION_GE(r,v,s) \
      63  	  (PERL_DECIMAL_VERSION >= PERL_VERSION_DECIMAL(r,v,s))
      64  #endif
      65  #ifndef PERL_VERSION_LE
      66  #  define PERL_VERSION_LE(r,v,s) \
      67  	  (PERL_DECIMAL_VERSION <= PERL_VERSION_DECIMAL(r,v,s))
      68  #endif
      69  
      70  /* XS_INTERNAL is the explicit static-linkage variant of the default
      71   * XS macro.
      72   *
      73   * XS_EXTERNAL is the same as XS_INTERNAL except it does not include
      74   * "STATIC", ie. it exports XSUB symbols. You probably don't want that
      75   * for anything but the BOOT XSUB.
      76   *
      77   * See XSUB.h in core!
      78   */
      79  
      80  
      81  /* TODO: This might be compatible further back than 5.10.0. */
      82  #if PERL_VERSION_GE(5, 10, 0) && PERL_VERSION_LE(5, 15, 1)
      83  #  undef XS_EXTERNAL
      84  #  undef XS_INTERNAL
      85  #  if defined(__CYGWIN__) && defined(USE_DYNAMIC_LOADING)
      86  #    define XS_EXTERNAL(name) __declspec(dllexport) XSPROTO(name)
      87  #    define XS_INTERNAL(name) STATIC XSPROTO(name)
      88  #  endif
      89  #  if defined(__SYMBIAN32__)
      90  #    define XS_EXTERNAL(name) EXPORT_C XSPROTO(name)
      91  #    define XS_INTERNAL(name) EXPORT_C STATIC XSPROTO(name)
      92  #  endif
      93  #  ifndef XS_EXTERNAL
      94  #    if defined(HASATTRIBUTE_UNUSED) && !defined(__cplusplus)
      95  #      define XS_EXTERNAL(name) void name(pTHX_ CV* cv __attribute__unused__)
      96  #      define XS_INTERNAL(name) STATIC void name(pTHX_ CV* cv __attribute__unused__)
      97  #    else
      98  #      ifdef __cplusplus
      99  #        define XS_EXTERNAL(name) extern "C" XSPROTO(name)
     100  #        define XS_INTERNAL(name) static XSPROTO(name)
     101  #      else
     102  #        define XS_EXTERNAL(name) XSPROTO(name)
     103  #        define XS_INTERNAL(name) STATIC XSPROTO(name)
     104  #      endif
     105  #    endif
     106  #  endif
     107  #endif
     108  
     109  /* perl >= 5.10.0 && perl <= 5.15.1 */
     110  
     111  
     112  /* The XS_EXTERNAL macro is used for functions that must not be static
     113   * like the boot XSUB of a module. If perl didn't have an XS_EXTERNAL
     114   * macro defined, the best we can do is assume XS is the same.
     115   * Dito for XS_INTERNAL.
     116   */
     117  #ifndef XS_EXTERNAL
     118  #  define XS_EXTERNAL(name) XS(name)
     119  #endif
     120  #ifndef XS_INTERNAL
     121  #  define XS_INTERNAL(name) XS(name)
     122  #endif
     123  
     124  /* Now, finally, after all this mess, we want an ExtUtils::ParseXS
     125   * internal macro that we're free to redefine for varying linkage due
     126   * to the EXPORT_XSUB_SYMBOLS XS keyword. This is internal, use
     127   * XS_EXTERNAL(name) or XS_INTERNAL(name) in your code if you need to!
     128   */
     129  
     130  #undef XS_EUPXS
     131  #if defined(PERL_EUPXS_ALWAYS_EXPORT)
     132  #  define XS_EUPXS(name) XS_EXTERNAL(name)
     133  #else
     134     /* default to internal */
     135  #  define XS_EUPXS(name) XS_INTERNAL(name)
     136  #endif
     137  
     138  #ifndef PERL_ARGS_ASSERT_CROAK_XS_USAGE
     139  #define PERL_ARGS_ASSERT_CROAK_XS_USAGE assert(cv); assert(params)
     140  
     141  /* prototype to pass -Wmissing-prototypes */
     142  STATIC void
     143  S_croak_xs_usage(const CV *const cv, const char *const params);
     144  
     145  STATIC void
     146  S_croak_xs_usage(const CV *const cv, const char *const params)
     147  {
     148      const GV *const gv = CvGV(cv);
     149  
     150      PERL_ARGS_ASSERT_CROAK_XS_USAGE;
     151  
     152      if (gv) {
     153          const char *const gvname = GvNAME(gv);
     154          const HV *const stash = GvSTASH(gv);
     155          const char *const hvname = stash ? HvNAME(stash) : NULL;
     156  
     157          if (hvname)
     158  	    Perl_croak_nocontext("Usage: %s::%s(%s)", hvname, gvname, params);
     159          else
     160  	    Perl_croak_nocontext("Usage: %s(%s)", gvname, params);
     161      } else {
     162          /* Pants. I don't think that it should be possible to get here. */
     163  	Perl_croak_nocontext("Usage: CODE(0x%" UVxf ")(%s)", PTR2UV(cv), params);
     164      }
     165  }
     166  #undef  PERL_ARGS_ASSERT_CROAK_XS_USAGE
     167  
     168  #define croak_xs_usage        S_croak_xs_usage
     169  
     170  #endif
     171  
     172  /* NOTE: the prototype of newXSproto() is different in versions of perls,
     173   * so we define a portable version of newXSproto()
     174   */
     175  #ifdef newXS_flags
     176  #define newXSproto_portable(name, c_impl, file, proto) newXS_flags(name, c_impl, file, proto, 0)
     177  #else
     178  #define newXSproto_portable(name, c_impl, file, proto) (PL_Sv=(SV*)newXS(name, c_impl, file), sv_setpv(PL_Sv, proto), (CV*)PL_Sv)
     179  #endif /* !defined(newXS_flags) */
     180  
     181  #if PERL_VERSION_LE(5, 21, 5)
     182  #  define newXS_deffile(a,b) Perl_newXS(aTHX_ a,b,file)
     183  #else
     184  #  define newXS_deffile(a,b) Perl_newXS_deffile(aTHX_ a,b)
     185  #endif
     186  
     187  #line 188 "XSParagraph.c"
     188  
     189  XS_EUPXS(XS_Texinfo__Convert__Paragraph_init); /* prototype to pass -Wmissing-prototypes */
     190  XS_EUPXS(XS_Texinfo__Convert__Paragraph_init)
     191  {
     192      dVAR; dXSARGS;
     193      if (items != 2)
     194         croak_xs_usage(cv,  "unused, unused2");
     195      {
     196  	int	unused = (int)SvIV(ST(0))
     197  ;
     198  	char *	unused2 = (char *)SvPV_nolen(ST(1))
     199  ;
     200  	int	RETVAL;
     201  	dXSTARG;
     202  
     203  	RETVAL = xspara_init(unused, unused2);
     204  	XSprePUSH; PUSHi((IV)RETVAL);
     205      }
     206      XSRETURN(1);
     207  }
     208  
     209  
     210  XS_EUPXS(XS_Texinfo__Convert__Paragraph_set_state); /* prototype to pass -Wmissing-prototypes */
     211  XS_EUPXS(XS_Texinfo__Convert__Paragraph_set_state)
     212  {
     213      dVAR; dXSARGS;
     214      if (items != 1)
     215         croak_xs_usage(cv,  "state");
     216      {
     217  	SV *	state = ST(0)
     218  ;
     219  
     220  	xspara_set_state(state);
     221      }
     222      XSRETURN_EMPTY;
     223  }
     224  
     225  
     226  XS_EUPXS(XS_Texinfo__Convert__Paragraph_new); /* prototype to pass -Wmissing-prototypes */
     227  XS_EUPXS(XS_Texinfo__Convert__Paragraph_new)
     228  {
     229      dVAR; dXSARGS;
     230      if (items < 1)
     231         croak_xs_usage(cv,  "class, ...");
     232      {
     233  	SV *	class = ST(0)
     234  ;
     235  #line 54 "XSParagraph.xs"
     236          HV *conf = 0;
     237          int id;
     238  #line 239 "XSParagraph.c"
     239  	SV *	RETVAL;
     240  #line 57 "XSParagraph.xs"
     241          items--;
     242          if (items > 0)
     243            {
     244              if (SvROK(ST(1)) && SvTYPE(SvRV(ST(1))) == SVt_PVHV)
     245                conf = (HV *) SvRV(ST(1));
     246            }
     247          id = xspara_new (conf);
     248  
     249          /* Create an integer, which the other functions
     250             need as their first argument. */
     251          RETVAL = newSViv (id);
     252  #line 253 "XSParagraph.c"
     253  	RETVAL = sv_2mortal(RETVAL);
     254  	ST(0) = RETVAL;
     255      }
     256      XSRETURN(1);
     257  }
     258  
     259  
     260  XS_EUPXS(XS_Texinfo__Convert__Paragraph_end_line_count); /* prototype to pass -Wmissing-prototypes */
     261  XS_EUPXS(XS_Texinfo__Convert__Paragraph_end_line_count)
     262  {
     263      dVAR; dXSARGS;
     264      if (items != 1)
     265         croak_xs_usage(cv,  "paragraph");
     266      {
     267  	SV *	paragraph = ST(0)
     268  ;
     269  	int	RETVAL;
     270  	dXSTARG;
     271  #line 76 "XSParagraph.xs"
     272          xspara_set_state (paragraph);
     273          RETVAL = xspara_end_line_count ();
     274  #line 275 "XSParagraph.c"
     275  	XSprePUSH; PUSHi((IV)RETVAL);
     276      }
     277      XSRETURN(1);
     278  }
     279  
     280  
     281  XS_EUPXS(XS_Texinfo__Convert__Paragraph_counter); /* prototype to pass -Wmissing-prototypes */
     282  XS_EUPXS(XS_Texinfo__Convert__Paragraph_counter)
     283  {
     284      dVAR; dXSARGS;
     285      if (items != 1)
     286         croak_xs_usage(cv,  "paragraph");
     287      {
     288  	SV *	paragraph = ST(0)
     289  ;
     290  	int	RETVAL;
     291  	dXSTARG;
     292  #line 85 "XSParagraph.xs"
     293          xspara_set_state (paragraph);
     294          RETVAL = xspara_counter ();
     295  #line 296 "XSParagraph.c"
     296  	XSprePUSH; PUSHi((IV)RETVAL);
     297      }
     298      XSRETURN(1);
     299  }
     300  
     301  
     302  XS_EUPXS(XS_Texinfo__Convert__Paragraph__end_line); /* prototype to pass -Wmissing-prototypes */
     303  XS_EUPXS(XS_Texinfo__Convert__Paragraph__end_line)
     304  {
     305      dVAR; dXSARGS;
     306      if (items != 1)
     307         croak_xs_usage(cv,  "paragraph");
     308      {
     309  	SV *	paragraph = ST(0)
     310  ;
     311  #line 94 "XSParagraph.xs"
     312          xspara_set_state (paragraph);
     313          xspara__end_line ();
     314  #line 315 "XSParagraph.c"
     315      }
     316      XSRETURN_EMPTY;
     317  }
     318  
     319  
     320  XS_EUPXS(XS_Texinfo__Convert__Paragraph_end_line); /* prototype to pass -Wmissing-prototypes */
     321  XS_EUPXS(XS_Texinfo__Convert__Paragraph_end_line)
     322  {
     323      dVAR; dXSARGS;
     324      if (items != 1)
     325         croak_xs_usage(cv,  "paragraph");
     326      {
     327  	SV *	paragraph = ST(0)
     328  ;
     329  	char *	RETVAL;
     330  	dXSTARG;
     331  #line 101 "XSParagraph.xs"
     332          xspara_set_state (paragraph);
     333          RETVAL = xspara_end_line ();
     334  #line 335 "XSParagraph.c"
     335  	sv_setpv(TARG, RETVAL); XSprePUSH; PUSHTARG;
     336      }
     337      XSRETURN(1);
     338  }
     339  
     340  
     341  XS_EUPXS(XS_Texinfo__Convert__Paragraph_get_pending); /* prototype to pass -Wmissing-prototypes */
     342  XS_EUPXS(XS_Texinfo__Convert__Paragraph_get_pending)
     343  {
     344      dVAR; dXSARGS;
     345      if (items != 1)
     346         croak_xs_usage(cv,  "paragraph");
     347      {
     348  	SV *	paragraph = ST(0)
     349  ;
     350  	char *	RETVAL;
     351  	dXSTARG;
     352  #line 110 "XSParagraph.xs"
     353          xspara_set_state (paragraph);
     354          RETVAL = xspara_get_pending ();
     355  #line 356 "XSParagraph.c"
     356  	sv_setpv(TARG, RETVAL); XSprePUSH; PUSHTARG;
     357      }
     358      XSRETURN(1);
     359  }
     360  
     361  
     362  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_pending_word); /* prototype to pass -Wmissing-prototypes */
     363  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_pending_word)
     364  {
     365      dVAR; dXSARGS;
     366      if (items < 1)
     367         croak_xs_usage(cv,  "paragraph, ...");
     368      {
     369  	SV *	paragraph = ST(0)
     370  ;
     371  #line 120 "XSParagraph.xs"
     372          int add_spaces = 0;
     373          char *retval;
     374  #line 375 "XSParagraph.c"
     375  	SV *	RETVAL;
     376  #line 123 "XSParagraph.xs"
     377          items -= 1;
     378          if (items > 0)
     379            {
     380              if (SvOK(ST(1)))
     381                {
     382                  add_spaces = (int)SvIV(ST(1));;
     383                }
     384            }
     385          xspara_set_state (paragraph);
     386          retval = xspara_add_pending_word (add_spaces);
     387  
     388          RETVAL = newSVpv (retval, 0);
     389          SvUTF8_on (RETVAL);
     390  #line 391 "XSParagraph.c"
     391  	RETVAL = sv_2mortal(RETVAL);
     392  	ST(0) = RETVAL;
     393      }
     394      XSRETURN(1);
     395  }
     396  
     397  
     398  XS_EUPXS(XS_Texinfo__Convert__Paragraph_end); /* prototype to pass -Wmissing-prototypes */
     399  XS_EUPXS(XS_Texinfo__Convert__Paragraph_end)
     400  {
     401      dVAR; dXSARGS;
     402      if (items != 1)
     403         croak_xs_usage(cv,  "paragraph");
     404      {
     405  	SV *	paragraph = ST(0)
     406  ;
     407  #line 143 "XSParagraph.xs"
     408          char *retval;
     409  #line 410 "XSParagraph.c"
     410  	SV *	RETVAL;
     411  #line 145 "XSParagraph.xs"
     412          xspara_set_state (paragraph);
     413          retval = xspara_end ();
     414  
     415          RETVAL = newSVpv (retval, 0);
     416          SvUTF8_on (RETVAL);
     417  #line 418 "XSParagraph.c"
     418  	RETVAL = sv_2mortal(RETVAL);
     419  	ST(0) = RETVAL;
     420      }
     421      XSRETURN(1);
     422  }
     423  
     424  
     425  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_text); /* prototype to pass -Wmissing-prototypes */
     426  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_text)
     427  {
     428      dVAR; dXSARGS;
     429      if (items != 2)
     430         croak_xs_usage(cv,  "paragraph, text_in");
     431      {
     432  	SV *	paragraph = ST(0)
     433  ;
     434  	SV *	text_in = ST(1)
     435  ;
     436  #line 159 "XSParagraph.xs"
     437          char *text;
     438          STRLEN text_len;
     439          TEXT retval;
     440  #line 441 "XSParagraph.c"
     441  	SV *	RETVAL;
     442  #line 163 "XSParagraph.xs"
     443          /* Always convert the input to UTF8 with sv_utf8_upgrade, so we can 
     444             process it properly in xspara_add_next. */
     445          if (!SvUTF8 (text_in))
     446            sv_utf8_upgrade (text_in);
     447  
     448          text = SvPV (text_in, text_len);
     449  
     450          xspara_set_state (paragraph);
     451          retval = xspara_add_text (text, text_len);
     452  
     453          RETVAL = newSVpv (retval.text ? retval.text : "", retval.end);
     454          SvUTF8_on (RETVAL);
     455  
     456  #line 457 "XSParagraph.c"
     457  	RETVAL = sv_2mortal(RETVAL);
     458  	ST(0) = RETVAL;
     459      }
     460      XSRETURN(1);
     461  }
     462  
     463  
     464  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_next); /* prototype to pass -Wmissing-prototypes */
     465  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_next)
     466  {
     467      dVAR; dXSARGS;
     468      if (items < 2)
     469         croak_xs_usage(cv,  "paragraph, text_in, ...");
     470      {
     471  	SV *	paragraph = ST(0)
     472  ;
     473  	SV *	text_in = ST(1)
     474  ;
     475  #line 184 "XSParagraph.xs"
     476          char *text;
     477          STRLEN text_len;
     478          TEXT retval;
     479          SV *arg_in;
     480          int transparent = 0;
     481  #line 482 "XSParagraph.c"
     482  	SV *	RETVAL;
     483  #line 190 "XSParagraph.xs"
     484          items -= 2;
     485          if (items > 0)
     486            {
     487              items--;
     488              arg_in = ST(2);
     489              if (SvOK(arg_in))
     490                transparent = (int)SvIV(arg_in);
     491            }
     492  
     493          /* Always convert the input to UTF8 with sv_utf8_upgrade, so we can 
     494             process it properly in xspara_add_next. */
     495          if (!SvUTF8 (text_in))
     496            sv_utf8_upgrade (text_in);
     497          text = SvPV (text_in, text_len);
     498  
     499          xspara_set_state (paragraph);
     500          retval = xspara_add_next (text, text_len, transparent);
     501  
     502          RETVAL = newSVpv (retval.text ? retval.text : "", retval.end);
     503          SvUTF8_on (RETVAL);
     504  
     505  #line 506 "XSParagraph.c"
     506  	RETVAL = sv_2mortal(RETVAL);
     507  	ST(0) = RETVAL;
     508      }
     509      XSRETURN(1);
     510  }
     511  
     512  
     513  XS_EUPXS(XS_Texinfo__Convert__Paragraph_remove_end_sentence); /* prototype to pass -Wmissing-prototypes */
     514  XS_EUPXS(XS_Texinfo__Convert__Paragraph_remove_end_sentence)
     515  {
     516      dVAR; dXSARGS;
     517      if (items != 1)
     518         croak_xs_usage(cv,  "paragraph");
     519      {
     520  	SV *	paragraph = ST(0)
     521  ;
     522  #line 219 "XSParagraph.xs"
     523          xspara_set_state (paragraph);
     524          xspara_remove_end_sentence ();
     525  #line 526 "XSParagraph.c"
     526      }
     527      XSRETURN_EMPTY;
     528  }
     529  
     530  
     531  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_end_sentence); /* prototype to pass -Wmissing-prototypes */
     532  XS_EUPXS(XS_Texinfo__Convert__Paragraph_add_end_sentence)
     533  {
     534      dVAR; dXSARGS;
     535      if (items != 2)
     536         croak_xs_usage(cv,  "paragraph, value");
     537      {
     538  	SV *	paragraph = ST(0)
     539  ;
     540  	SV *	value = ST(1)
     541  ;
     542  #line 227 "XSParagraph.xs"
     543          int intvalue = 0;
     544  #line 545 "XSParagraph.c"
     545  #line 229 "XSParagraph.xs"
     546          if (SvOK(value))
     547            intvalue = (int)SvIV(value);
     548          xspara_set_state (paragraph);
     549          xspara_add_end_sentence (intvalue);
     550  #line 551 "XSParagraph.c"
     551      }
     552      XSRETURN_EMPTY;
     553  }
     554  
     555  
     556  XS_EUPXS(XS_Texinfo__Convert__Paragraph_allow_end_sentence); /* prototype to pass -Wmissing-prototypes */
     557  XS_EUPXS(XS_Texinfo__Convert__Paragraph_allow_end_sentence)
     558  {
     559      dVAR; dXSARGS;
     560      if (items != 1)
     561         croak_xs_usage(cv,  "paragraph");
     562      {
     563  	SV *	paragraph = ST(0)
     564  ;
     565  #line 238 "XSParagraph.xs"
     566          xspara_set_state (paragraph);
     567          xspara_allow_end_sentence ();
     568  #line 569 "XSParagraph.c"
     569      }
     570      XSRETURN_EMPTY;
     571  }
     572  
     573  
     574  XS_EUPXS(XS_Texinfo__Convert__Paragraph_set_space_protection); /* prototype to pass -Wmissing-prototypes */
     575  XS_EUPXS(XS_Texinfo__Convert__Paragraph_set_space_protection)
     576  {
     577      dVAR; dXSARGS;
     578      if (items < 2)
     579         croak_xs_usage(cv,  "paragraph, space_protection_in, ...");
     580      {
     581  	SV *	paragraph = ST(0)
     582  ;
     583  	SV *	space_protection_in = ST(1)
     584  ;
     585  #line 249 "XSParagraph.xs"
     586          int space_protection = -1;
     587          int ignore_columns = -1;
     588          int keep_end_lines = -1;
     589          int french_spacing = -1;
     590          int double_width_no_break = -1;
     591          SV *arg_in;
     592  #line 593 "XSParagraph.c"
     593  #line 256 "XSParagraph.xs"
     594          if (SvOK(space_protection_in))
     595            space_protection = (int)SvIV(space_protection_in);
     596          /* Get optional arguments from stack. */
     597          items -= 2;
     598          if (items > 0)
     599            {
     600              items--;
     601              arg_in = ST(2);
     602              if (SvOK(arg_in))
     603                ignore_columns = (int)SvIV(arg_in);
     604            }
     605          if (items > 0)
     606            {
     607              items--;
     608              arg_in = ST(3);
     609              if (SvOK(arg_in))
     610                keep_end_lines = (int)SvIV(arg_in);
     611            }
     612          if (items > 0)
     613            {
     614              items--;
     615              arg_in = ST(4);
     616              if (SvOK(arg_in))
     617                french_spacing = (int)SvIV(arg_in);
     618            }
     619          if (items > 0)
     620            {
     621              items--;
     622              arg_in = ST(5);
     623              if (SvOK(arg_in))
     624                double_width_no_break = (int)SvIV(arg_in);
     625            }
     626  
     627          xspara_set_state (paragraph);
     628          xspara_set_space_protection
     629            (space_protection, ignore_columns, keep_end_lines,
     630             french_spacing, double_width_no_break);
     631  #line 632 "XSParagraph.c"
     632      }
     633      XSRETURN_EMPTY;
     634  }
     635  
     636  #ifdef __cplusplus
     637  extern "C"
     638  #endif
     639  XS_EXTERNAL(boot_Texinfo__Convert__Paragraph); /* prototype to pass -Wmissing-prototypes */
     640  XS_EXTERNAL(boot_Texinfo__Convert__Paragraph)
     641  {
     642  #if PERL_VERSION_LE(5, 21, 5)
     643      dVAR; dXSARGS;
     644  #else
     645      dVAR; dXSBOOTARGSXSAPIVERCHK;
     646  #endif
     647  #if (PERL_REVISION == 5 && PERL_VERSION < 9)
     648      char* file = __FILE__;
     649  #else
     650      const char* file = __FILE__;
     651  #endif
     652  
     653      PERL_UNUSED_VAR(file);
     654  
     655      PERL_UNUSED_VAR(cv); /* -W */
     656      PERL_UNUSED_VAR(items); /* -W */
     657  #if PERL_VERSION_LE(5, 21, 5)
     658      XS_VERSION_BOOTCHECK;
     659  #  ifdef XS_APIVERSION_BOOTCHECK
     660      XS_APIVERSION_BOOTCHECK;
     661  #  endif
     662  #endif
     663  
     664          (void)newXSproto_portable("Texinfo::Convert::Paragraph::init", XS_Texinfo__Convert__Paragraph_init, file, "$$");
     665          (void)newXSproto_portable("Texinfo::Convert::Paragraph::set_state", XS_Texinfo__Convert__Paragraph_set_state, file, "$");
     666          (void)newXSproto_portable("Texinfo::Convert::Paragraph::new", XS_Texinfo__Convert__Paragraph_new, file, "$;@");
     667          (void)newXSproto_portable("Texinfo::Convert::Paragraph::end_line_count", XS_Texinfo__Convert__Paragraph_end_line_count, file, "$");
     668          (void)newXSproto_portable("Texinfo::Convert::Paragraph::counter", XS_Texinfo__Convert__Paragraph_counter, file, "$");
     669          (void)newXSproto_portable("Texinfo::Convert::Paragraph::_end_line", XS_Texinfo__Convert__Paragraph__end_line, file, "$");
     670          (void)newXSproto_portable("Texinfo::Convert::Paragraph::end_line", XS_Texinfo__Convert__Paragraph_end_line, file, "$");
     671          (void)newXSproto_portable("Texinfo::Convert::Paragraph::get_pending", XS_Texinfo__Convert__Paragraph_get_pending, file, "$");
     672          (void)newXSproto_portable("Texinfo::Convert::Paragraph::add_pending_word", XS_Texinfo__Convert__Paragraph_add_pending_word, file, "$;@");
     673          (void)newXSproto_portable("Texinfo::Convert::Paragraph::end", XS_Texinfo__Convert__Paragraph_end, file, "$");
     674          (void)newXSproto_portable("Texinfo::Convert::Paragraph::add_text", XS_Texinfo__Convert__Paragraph_add_text, file, "$$");
     675          (void)newXSproto_portable("Texinfo::Convert::Paragraph::add_next", XS_Texinfo__Convert__Paragraph_add_next, file, "$$;@");
     676          (void)newXSproto_portable("Texinfo::Convert::Paragraph::remove_end_sentence", XS_Texinfo__Convert__Paragraph_remove_end_sentence, file, "$");
     677          (void)newXSproto_portable("Texinfo::Convert::Paragraph::add_end_sentence", XS_Texinfo__Convert__Paragraph_add_end_sentence, file, "$$");
     678          (void)newXSproto_portable("Texinfo::Convert::Paragraph::allow_end_sentence", XS_Texinfo__Convert__Paragraph_allow_end_sentence, file, "$");
     679          (void)newXSproto_portable("Texinfo::Convert::Paragraph::set_space_protection", XS_Texinfo__Convert__Paragraph_set_space_protection, file, "$$;@");
     680  #if PERL_VERSION_LE(5, 21, 5)
     681  #  if PERL_VERSION_GE(5, 9, 0)
     682      if (PL_unitcheckav)
     683          call_list(PL_scopestack_ix, PL_unitcheckav);
     684  #  endif
     685      XSRETURN_YES;
     686  #else
     687      Perl_xs_boot_epilog(aTHX_ ax);
     688  #endif
     689  }
     690