public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/60943] [C++1y] Return type deduction interferes with ref-qualifiers
       [not found] <bug-60943-4@http.gcc.gnu.org/bugzilla/>
@ 2014-11-23 14:40 ` paolo.carlini at oracle dot com
  2015-03-27 11:55 ` redi at gcc dot gnu.org
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 5+ messages in thread
From: paolo.carlini at oracle dot com @ 2014-11-23 14:40 UTC (permalink / raw)
  To: gcc-bugs

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

Paolo Carlini <paolo.carlini at oracle dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2014-11-23
                 CC|Casey at Carter dot net            |
     Ever confirmed|0                           |1


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

* [Bug c++/60943] [C++1y] Return type deduction interferes with ref-qualifiers
       [not found] <bug-60943-4@http.gcc.gnu.org/bugzilla/>
  2014-11-23 14:40 ` [Bug c++/60943] [C++1y] Return type deduction interferes with ref-qualifiers paolo.carlini at oracle dot com
@ 2015-03-27 11:55 ` redi at gcc dot gnu.org
  2015-05-21 20:51 ` [Bug c++/60943] [C++14] " nathan at gcc dot gnu.org
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 5+ messages in thread
From: redi at gcc dot gnu.org @ 2015-03-27 11:55 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |anders at sjogren dot info

--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
*** Bug 65599 has been marked as a duplicate of this bug. ***


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

* [Bug c++/60943] [C++14] Return type deduction interferes with ref-qualifiers
       [not found] <bug-60943-4@http.gcc.gnu.org/bugzilla/>
  2014-11-23 14:40 ` [Bug c++/60943] [C++1y] Return type deduction interferes with ref-qualifiers paolo.carlini at oracle dot com
  2015-03-27 11:55 ` redi at gcc dot gnu.org
@ 2015-05-21 20:51 ` nathan at gcc dot gnu.org
  2015-05-21 20:52 ` nathan at gcc dot gnu.org
  2015-05-22  6:18 ` anders at sjogren dot info
  4 siblings, 0 replies; 5+ messages in thread
From: nathan at gcc dot gnu.org @ 2015-05-21 20:51 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
Author: nathan
Date: Thu May 21 20:50:45 2015
New Revision: 223502

URL: https://gcc.gnu.org/viewcvs?rev=223502&root=gcc&view=rev
Log:
        cp/
        PR c++/60943
        * decl2.c (change_return_type): Propagate FUNCTION_REF_QUALIFIED.

        testsuite/
        * g++.dg/cpp1y/pr60943.C: New.

Added:
    trunk/gcc/testsuite/g++.dg/cpp1y/pr60943.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/decl2.c
    trunk/gcc/testsuite/ChangeLog


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

* [Bug c++/60943] [C++14] Return type deduction interferes with ref-qualifiers
       [not found] <bug-60943-4@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2015-05-21 20:51 ` [Bug c++/60943] [C++14] " nathan at gcc dot gnu.org
@ 2015-05-21 20:52 ` nathan at gcc dot gnu.org
  2015-05-22  6:18 ` anders at sjogren dot info
  4 siblings, 0 replies; 5+ messages in thread
From: nathan at gcc dot gnu.org @ 2015-05-21 20:52 UTC (permalink / raw)
  To: gcc-bugs

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

Nathan Sidwell <nathan at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #3 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
Propagate ref qualifier to new function type.


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

* [Bug c++/60943] [C++14] Return type deduction interferes with ref-qualifiers
       [not found] <bug-60943-4@http.gcc.gnu.org/bugzilla/>
                   ` (3 preceding siblings ...)
  2015-05-21 20:52 ` nathan at gcc dot gnu.org
@ 2015-05-22  6:18 ` anders at sjogren dot info
  4 siblings, 0 replies; 5+ messages in thread
From: anders at sjogren dot info @ 2015-05-22  6:18 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Anders Sjögren <anders at sjogren dot info> ---
Thanks for fixing the bug!

It seems that the test file
https://gcc.gnu.org/viewcvs/gcc/trunk/gcc/testsuite/g%2B%2B.dg/cpp1y/pr60943.C?view=markup&pathrev=223502
contains an error.

It contains:
void Bar (A &&a)
{
  a.f ();
}

My guess is that it was meant to call the member function from an R-value
object a. However, as an l-value at the site of the call, and both Foo and Bar
will select the l-value version. Something like std::move(a).f() or just
A{}.f(); should do the trick.
>From gcc-bugs-return-487030-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri May 22 06:20:54 2015
Return-Path: <gcc-bugs-return-487030-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 109814 invoked by alias); 22 May 2015 06:20:54 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 109762 invoked by uid 48); 22 May 2015 06:20:50 -0000
From: "anders at sjogren dot info" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/60943] [C++14] Return type deduction interferes with ref-qualifiers
Date: Fri, 22 May 2015 06:20:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.8.2
X-Bugzilla-Keywords: rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: anders at sjogren dot info
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: nathan at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-60943-4-cMgvAYFMnh@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-60943-4@http.gcc.gnu.org/bugzilla/>
References: <bug-60943-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-05/txt/msg01870.txt.bz2
Content-length: 266

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

--- Comment #5 from Anders Sjögren <anders at sjogren dot info> ---
A typo snuck in...
"However, as an l-value at the site of the call[...]"
should be
"However, a is an l-value at the site of the call[...]"
>From gcc-bugs-return-487031-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri May 22 06:38:43 2015
Return-Path: <gcc-bugs-return-487031-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 107263 invoked by alias); 22 May 2015 06:38:43 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 107124 invoked by uid 48); 22 May 2015 06:38:39 -0000
From: "anders at sjogren dot info" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/60943] [C++14] Return type deduction interferes with ref-qualifiers
Date: Fri, 22 May 2015 06:38:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.8.2
X-Bugzilla-Keywords: rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: anders at sjogren dot info
X-Bugzilla-Status: RESOLVED
X-Bugzilla-Resolution: FIXED
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: nathan at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-60943-4-EFHIIrt07a@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-60943-4@http.gcc.gnu.org/bugzilla/>
References: <bug-60943-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-05/txt/msg01871.txt.bz2
Content-length: 673

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

--- Comment #6 from Anders Sjögren <anders at sjogren dot info> ---
An alternative test case, which also tests that the correct version is
selected, could be:

#include <type_traits>

using expected_lvalue_res_t = int;
using expected_rvalue_res_t = double;

struct A {
  auto f() & {return expected_lvalue_res_t{};}
  auto f() && {return expected_rvalue_res_t{};}
};

void lvalue_assert()
{
  A a;
  a.f();
  static_assert(std::is_same<decltype(a.f()),
expected_lvalue_res_t>::value,"");
}

void rvalue_assert()
{
  A{}.f();
  static_assert(std::is_same<decltype(A{}.f()),
expected_rvalue_res_t>::value,"");
}
>From gcc-bugs-return-487032-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri May 22 06:41:08 2015
Return-Path: <gcc-bugs-return-487032-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 113327 invoked by alias); 22 May 2015 06:41:08 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 111423 invoked by uid 48); 22 May 2015 06:41:04 -0000
From: "Joost.VandeVondele at mat dot ethz.ch" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/66251] New: [6 Regression] ICE in vect_get_vec_def_for_operand, at tree-vect-stmts.c:1484
Date: Fri, 22 May 2015 06:41:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: middle-end
X-Bugzilla-Version: 6.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: Joost.VandeVondele at mat dot ethz.ch
X-Bugzilla-Status: UNCONFIRMED
X-Bugzilla-Resolution:
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone
Message-ID: <bug-66251-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2015-05/txt/msg01872.txt.bz2
Content-length: 1742

https://gcc.gnu.org/bugzilla/show_bug.cgi?idf251

            Bug ID: 66251
           Summary: [6 Regression] ICE in vect_get_vec_def_for_operand, at
                    tree-vect-stmts.c:1484
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: middle-end
          Assignee: unassigned at gcc dot gnu.org
          Reporter: Joost.VandeVondele at mat dot ethz.ch
  Target Milestone: ---

recent regression (last day):

gcc version 6.0.0 20150522 (experimental) [trunk revision 223512] (GCC)

> cat bug.f90
SUBROUTINE dbcsr_data_convert (n)
  COMPLEX(KIND=4), DIMENSION(:), POINTER :: s_data_c
  COMPLEX(KIND=8), DIMENSION(:), POINTER :: t_data_z
  t_data_z(1:n) = CMPLX(s_data_c(1:n), KIND=8)
  CALL foo()
END SUBROUTINE dbcsr_data_convert

> gfortran -c -O3 bug.f90
bug.f90:1:0:

 SUBROUTINE dbcsr_data_convert (n)
^
internal compiler error: in vect_get_vec_def_for_operand, at
tree-vect-stmts.c:1484
0xd97159 vect_get_vec_def_for_operand(tree_node*, gimple_statement_base*,
tree_node**)
        ../../gcc/gcc/tree-vect-stmts.c:1484
0xda51e3 vectorizable_store
        ../../gcc/gcc/tree-vect-stmts.c:5315
0xda7fbd vect_transform_stmt(gimple_statement_base*, gimple_stmt_iterator*,
bool*, _slp_tree*, _slp_instance*)
        ../../gcc/gcc/tree-vect-stmts.c:7466
0xdc6279 vect_schedule_slp_instance
        ../../gcc/gcc/tree-vect-slp.c:3502
0xdc6a90 vect_schedule_slp(_loop_vec_info*, _bb_vec_info*)
        ../../gcc/gcc/tree-vect-slp.c:3572
0xdafdf7 vect_transform_loop(_loop_vec_info*)
        ../../gcc/gcc/tree-vect-loop.c:6165
0xdcea3e vectorize_loops()
        ../../gcc/gcc/tree-vectorizer.c:502
Please submit a full bug report,


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

end of thread, other threads:[~2015-05-22  6:18 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-60943-4@http.gcc.gnu.org/bugzilla/>
2014-11-23 14:40 ` [Bug c++/60943] [C++1y] Return type deduction interferes with ref-qualifiers paolo.carlini at oracle dot com
2015-03-27 11:55 ` redi at gcc dot gnu.org
2015-05-21 20:51 ` [Bug c++/60943] [C++14] " nathan at gcc dot gnu.org
2015-05-21 20:52 ` nathan at gcc dot gnu.org
2015-05-22  6:18 ` anders at sjogren dot info

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).