Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BBC: Blead Breaks JSON::DWIW #22685

Open
cjg-cguevara opened this issue Oct 21, 2024 · 7 comments
Open

BBC: Blead Breaks JSON::DWIW #22685

cjg-cguevara opened this issue Oct 21, 2024 · 7 comments
Labels
BBC Blead Breaks CPAN - changes in blead broke a cpan module(s)

Comments

@cjg-cguevara
Copy link

This is a bug report for perl from "Carlos Guevara" carlos@carlosguevara.com,
generated with the help of perlbug 1.43 running under perl 5.41.6.


BBC: Blead Breaks JSON::DWIW

Please see http://fast-matrix.cpantesters.org/?dist=JSON::DWIW


Flags

  • category=core
  • severity=low

Perl configuration

Site configuration information for perl 5.41.6:

Configured by cpan at Sun Oct 20 22:36:51 EDT 2024.

Summary of my perl5 (revision 5 version 41 subversion 6) configuration:
  Commit id: cb2baa70118e364c1428dc77cb8f9c614060c26e
  Platform:
    osname=linux
    osvers=5.14.0-427.40.1.el9_4.x86_64
    archname=x86_64-linux
    uname='linux cjg-rhel9 5.14.0-427.40.1.el9_4.x86_64 #1 smp preempt_dynamic fri oct 4 15:22:45 edt 2024 x86_64 x86_64 x86_64 gnulinux '
    config_args='-des -Dprefix=/home/cpan/bin/perl -Dscriptdir=/home/cpan/bin/perl/bin -Dusedevel -Duse64bitall'
    hint=recommended
    useposix=true
    d_sigaction=define
    useithreads=undef
    usemultiplicity=undef
    use64bitint=define
    use64bitall=define
    uselongdouble=undef
    usemymalloc=n
    default_inc_excludes_dot=define
  Compiler:
    cc='cc'
    ccflags ='-fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2'
    optimize='-O2'
    cppflags='-fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include'
    ccversion=''
    gccversion='11.4.1 20231218 (Red Hat 11.4.1-3)'
    gccosandvers=''
    intsize=4
    longsize=8
    ptrsize=8
    doublesize=8
    byteorder=12345678
    doublekind=3
    d_longlong=define
    longlongsize=8
    d_longdbl=define
    longdblsize=16
    longdblkind=3
    ivtype='long'
    ivsize=8
    nvtype='double'
    nvsize=8
    Off_t='off_t'
    lseeksize=8
    alignbytes=8
    prototype=define
  Linker and Libraries:
    ld='cc'
    ldflags =' -fstack-protector-strong -L/usr/local/lib'
    libpth=/usr/local/lib /usr/lib /usr/lib64 /usr/local/lib64
    libs=-lpthread -ldb -ldl -lm -lcrypt -lutil -lc
    perllibs=-lpthread -ldl -lm -lcrypt -lutil -lc
    libc=/lib/../lib64/libc.so.6
    so=so
    useshrplib=false
    libperl=libperl.a
    gnulibc_version='2.34'
  Dynamic Linking:
    dlsrc=dl_dlopen.xs
    dlext=so
    d_dlsymun=undef
    ccdlflags='-Wl,-E'
    cccdlflags='-fPIC'
    lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector-strong'


---
@INC for perl 5.41.6:
    /home/cpan/bin/perl/lib/site_perl/5.41.6/x86_64-linux
    /home/cpan/bin/perl/lib/site_perl/5.41.6
    /home/cpan/bin/perl/lib/5.41.6/x86_64-linux
    /home/cpan/bin/perl/lib/5.41.6

---
Environment for perl 5.41.6:
    HOME=/home/cpan
    LANG=en_US.UTF-8
    LANGUAGE (unset)
    LC_ALL=C
    LD_LIBRARY_PATH (unset)
    LOGDIR (unset)
    PATH=/home/cpan/bin/perl/bin:/home/cpan/bin:/usr/share/Modules/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin
    PERL_BADLANG (unset)
    SHELL=/bin/bash
@haarg
Copy link
Contributor

haarg commented Oct 21, 2024

This, along with #22686, #22687, and #22688, were broken by #22647.

@iabyn can you take a look?

@mauke
Copy link
Contributor

mauke commented Oct 21, 2024

Error message:

Unparseable XSUB parameter: 'SV *' in DWIW.xs, line 1775

@iabyn
Copy link
Contributor

iabyn commented Oct 21, 2024 via email

@jkeenan jkeenan added BBC Blead Breaks CPAN - changes in blead broke a cpan module(s) and removed Needs Triage labels Oct 21, 2024
@jkeenan
Copy link
Contributor

jkeenan commented Oct 21, 2024

The breaking commit:

commit a399a4923c7f15aa1aa5bdb38a5dccf59ef51678
Author:     David Mitchell <davem@iabyn.nospamdeletethisbit.com>
AuthorDate: Mon Sep 23 18:52:11 2024 +0100
Commit:     David Mitchell <davem@iabyn.nospamdeletethisbit.com>
CommitDate: Fri Oct 18 11:12:17 2024 +0100

    ParseXS: refactor: XSUB signature-processing

@iabyn
Copy link
Contributor

iabyn commented Oct 22, 2024 via email

@tonycoz
Copy link
Contributor

tonycoz commented Oct 22, 2024

We could officially sanction 'SV*' as the text for a placeholder parameter
i.e. the XS equivalent of perl's ($a, undef, $b) = (...).

I've done that with a name but no defined type in the past:

Imager::IO
io_new_bufchain(class)
    CODE:
	RETVAL = io_new_bufchain();
    OUTPUT:
        RETVAL

@iabyn
Copy link
Contributor

iabyn commented Nov 18, 2024

I've just created PR #22761 with two commits.

The first just adds tests to confirm that using a parameter without a type acts as a placeholder (as it always has).

The second commit addresses this ticket and also ticket #22686, which are both concerned with using 'SV *' as a placeholder. Traditionally, XS silently ignored any parameter declaration it couldn't parse: so acting as a placeholder as a side-effect. My recent work made unparseable parameter declarations an error, which broke these two distributions. This commit makes an explicit exception for 'SV *', which now acts as a placeholder again. Any other unrecognised parameter declaration is still a syntax error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BBC Blead Breaks CPAN - changes in blead broke a cpan module(s)
Projects
None yet
Development

No branches or pull requests

6 participants