public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/100992] New: Wrong result for is_constructible for const ref of tuple of tuples
@ 2021-06-09 13:45 kirshamir at gmail dot com
  2021-06-09 14:39 ` [Bug libstdc++/100992] " redi at gcc dot gnu.org
  2021-06-09 15:15 ` kirshamir at gmail dot com
  0 siblings, 2 replies; 3+ messages in thread
From: kirshamir at gmail dot com @ 2021-06-09 13:45 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100992

            Bug ID: 100992
           Summary: Wrong result for is_constructible for const ref of
                    tuple of tuples
           Product: gcc
           Version: 11.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: kirshamir at gmail dot com
                CC: kirshamir at gmail dot com
  Target Milestone: ---

The second static_assert below fails, should pass:

#include <tuple>

struct F {
    F() { }
    F(const std::tuple<F>& foo) {}
};

static_assert(std::is_constructible_v<F, const std::tuple<F>&>);
static_assert(std::is_constructible_v<F, const std::tuple<std::tuple<F>>&>); //
fails, unjustifiably

int main() {
    F f1{std::tuple{F{}}};
    auto tup = std::tuple{std::tuple{f1}};
    F f2{tup}; // constructible
}

https://godbolt.org/z/3KfbxfhWE

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug libstdc++/100992] Wrong result for is_constructible for const ref of tuple of tuples
  2021-06-09 13:45 [Bug c++/100992] New: Wrong result for is_constructible for const ref of tuple of tuples kirshamir at gmail dot com
@ 2021-06-09 14:39 ` redi at gcc dot gnu.org
  2021-06-09 15:15 ` kirshamir at gmail dot com
  1 sibling, 0 replies; 3+ messages in thread
From: redi at gcc dot gnu.org @ 2021-06-09 14:39 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100992

Jonathan Wakely <redi at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
          Component|c++                         |libstdc++
   Last reconfirmed|                            |2021-06-09
             Status|UNCONFIRMED                 |NEW

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
I think this is a dup

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug libstdc++/100992] Wrong result for is_constructible for const ref of tuple of tuples
  2021-06-09 13:45 [Bug c++/100992] New: Wrong result for is_constructible for const ref of tuple of tuples kirshamir at gmail dot com
  2021-06-09 14:39 ` [Bug libstdc++/100992] " redi at gcc dot gnu.org
@ 2021-06-09 15:15 ` kirshamir at gmail dot com
  1 sibling, 0 replies; 3+ messages in thread
From: kirshamir at gmail dot com @ 2021-06-09 15:15 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100992

--- Comment #2 from Amir Kirsh <kirshamir at gmail dot com> ---
Maybe a dup of:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96592

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-06-09 15:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-09 13:45 [Bug c++/100992] New: Wrong result for is_constructible for const ref of tuple of tuples kirshamir at gmail dot com
2021-06-09 14:39 ` [Bug libstdc++/100992] " redi at gcc dot gnu.org
2021-06-09 15:15 ` kirshamir at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).