develooper Front page | perl.perl5.porters | Postings from July 2018

[perl #133321] locale.c: Fix conditional compilation

Thread Next
From:
Francois PERRAD via RT
Date:
July 9, 2018 06:31
Subject:
[perl #133321] locale.c: Fix conditional compilation
Message ID:
rt-4.0.24-2735-1531117906-1929.133321-15-0@perl.org
On Sat, 07 Jul 2018 14:49:26 -0700, khw wrote:
> On Sun, 01 Jul 2018 21:46:51 -0700, fperrad wrote:
> > This is a bug report for perl from francois.perrad@gadz.org,
> > generated with the help of perlbug 1.41 running under perl 5.28.0.
> >
> >
> > -----------------------------------------------------------------
> > [Please describe your issue here]
> >
> > With Perl 5.28.0, there are some mismatches between blocks
> > and conditional compilation in the Perl__is_cur_LC_category_utf8()
> > function.
> > The compilation of miniperl could fails like this:
> > ```
> > locale.c: In function `Perl__is_cur_LC_category_utf8`:
> > locale.c:5481:1: error: expected declaration or statement at end of
> > input
> >  }
> >  ^
> > ```
> 
> Could you try this on blead and let us know?  There have been a bunch
> of changes to address things like this, and I think the problem may be
> moot.

The issue is still here on blead (7e7bdfd).
The issue is not present in 5.26 branch.

It occurs with a toolchain using uClibc 1.0.30, but everything is OK when using glibc or musl.

Any editor with collapse/expand block capability will show you that blocks and conditional compilation are not properly balanced in the function `Perl__is_cur_LC_category_utf8`.

Fran├žois

> >
> > The attached patch fixes the issue.
> >


---
via perlbug:  queue: perl5 status: open
https://rt.perl.org/Ticket/Display.html?id=133321

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About