[llvm-bugs] [Bug 28598] Assigning a gsl::span<const int> to a gsl::span<int> const causes segmentation fault during compilation.

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Mar 11 06:10:17 PDT 2020


https://bugs.llvm.org/show_bug.cgi?id=28598

Nico Weber <nicolasweber at gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED
                 CC|                            |nicolasweber at gmx.de

--- Comment #1 from Nico Weber <nicolasweber at gmx.de> ---
No longer seems to repro at trunk:

$ ~/src/llvm-project/out/gn/bin/clang -c main.cpp  -std=c++14
main.cpp:15:7: error: cannot initialize a member subobject of type
'add_pointer_t<int>' with an lvalue of type 'const add_pointer_t<const int>'
      data_(other.data_)
      ^     ~~~~~~~~~~~
main.cpp:30:26: note: in instantiation of function template specialization
'span<int>::span<const int>' requested here
  span<int> const span = getSpan();
                         ^
1 error generated.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200311/ec76d564/attachment-0001.html>


More information about the llvm-bugs mailing list