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

compile failure with recent GCC #35

Open
dslarm opened this issue Feb 24, 2025 · 0 comments
Open

compile failure with recent GCC #35

dslarm opened this issue Feb 24, 2025 · 0 comments

Comments

@dslarm
Copy link

dslarm commented Feb 24, 2025

Attempting to build the bioconda package - with 1.0.13 (and prior versions), GNU 13.3.0 yields an error preventing compilation:

14:49:26 BIOCONDA INFO (OUT) /opt/conda/conda-bld/ont_vbz_hdf_plugin_1740408436260/work/vbz/vbz.cpp: In function 'vbz_size_t vbz_decompressed_size(const void*, vbz_size_t, const CompressionOptions*)':
14:49:26 BIOCONDA INFO (OUT) /opt/conda/conda-bld/ont_vbz_hdf_plugin_1740408436260/work/vbz/vbz.cpp:384:17: error: possibly dangling reference to a temporary [-Werror=dangling-reference]
14:49:26 BIOCONDA INFO (OUT)   384 |     auto const& source_header = source_buffer.subspan(0, sizeof(VbzSizedHeader)).as_span<VbzSizedHeader const>()[0];
14:49:26 BIOCONDA INFO (OUT)       |                 ^~~~~~~~~~~~~
14:49:26 BIOCONDA INFO (OUT) /opt/conda/conda-bld/ont_vbz_hdf_plugin_1740408436260/work/vbz/vbz.cpp:384:115: note: the temporary was destroyed at the end of the full expression 'source_buffer.gsl::span<const char>::subspan(0, sizeof ({anonymous}::VbzSizedHeader)).gsl::span<const char>::as_span<const {anonymous}::VbzSizedHeader>().gsl::span<const {anonymous}::VbzSizedHeader>::operator[](0)'
14:49:26 BIOCONDA INFO (OUT)   384 |     auto const& source_header = source_buffer.subspan(0, sizeof(VbzSizedHeader)).as_span<VbzSizedHeader const>()[0];
14:49:26 BIOCONDA INFO (OUT)       |                                                                                                                   ^
14:49:26 BIOCONDA INFO (OUT) cc1plus: all warnings being treated as errors

pinning the compiler back to GCC 12, the problem disappears.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant