diff options
author | David Golden <dagolden@cpan.org> | 2010-01-16 18:03:52 -0500 |
---|---|---|
committer | David Golden <dagolden@cpan.org> | 2010-01-16 18:03:52 -0500 |
commit | 8d08d9baca8b5e17813fd3fbfe3510d7ba6097f7 (patch) | |
tree | f31298fde9d8dabf17a3248d4f4587886c2fe763 /toke.c | |
parent | b386fa440d8266b7c2eb26f47b6c2a7d315a0128 (diff) | |
download | perl-8d08d9baca8b5e17813fd3fbfe3510d7ba6097f7.tar.gz |
Parse 'use NAME VERSION' with C locale
Diffstat (limited to 'toke.c')
-rw-r--r-- | toke.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -2093,7 +2093,13 @@ S_force_version(pTHX_ char *s, int guessing) #endif if (*d == ';' || isSPACE(*d) || *d == '}' || !*d) { SV *ver; +#ifdef USE_LOCALE_NUMERIC + char *loc = setlocale(LC_NUMERIC, "C"); +#endif s = scan_num(s, &pl_yylval); +#ifdef USE_LOCALE_NUMERIC + setlocale(LC_NUMERIC, loc); +#endif version = pl_yylval.opval; ver = cSVOPx(version)->op_sv; if (SvPOK(ver) && !SvNIOK(ver)) { |