Re: [C++ PATCH] Constexpr fold even some TREE_CONSTANT ctors (PR c++/87934)

2018-12-20 Thread Jason Merrill
On 12/19/18 6:14 PM, Jakub Jelinek wrote: On Tue, Dec 18, 2018 at 10:27:56PM -0500, Jason Merrill wrote: On 12/18/18 6:19 PM, Jakub Jelinek wrote: On Tue, Dec 18, 2018 at 05:40:03PM -0500, Jason Merrill wrote: On 12/18/18 3:45 PM, Jakub Jelinek wrote: The following testcase FAILs, because par

Re: [C++ PATCH] Constexpr fold even some TREE_CONSTANT ctors (PR c++/87934)

2018-12-19 Thread Jakub Jelinek
On Tue, Dec 18, 2018 at 10:27:56PM -0500, Jason Merrill wrote: > On 12/18/18 6:19 PM, Jakub Jelinek wrote: > > On Tue, Dec 18, 2018 at 05:40:03PM -0500, Jason Merrill wrote: > > > On 12/18/18 3:45 PM, Jakub Jelinek wrote: > > > > The following testcase FAILs, because parsing creates a TREE_CONSTANT

Re: [C++ PATCH] Constexpr fold even some TREE_CONSTANT ctors (PR c++/87934)

2018-12-18 Thread Jason Merrill
On 12/18/18 6:19 PM, Jakub Jelinek wrote: On Tue, Dec 18, 2018 at 05:40:03PM -0500, Jason Merrill wrote: On 12/18/18 3:45 PM, Jakub Jelinek wrote: The following testcase FAILs, because parsing creates a TREE_CONSTANT CONSTRUCTOR that contains CONST_DECL elts. cp_fold_r can handle that, but con

Re: [C++ PATCH] Constexpr fold even some TREE_CONSTANT ctors (PR c++/87934)

2018-12-18 Thread Jakub Jelinek
On Tue, Dec 18, 2018 at 05:40:03PM -0500, Jason Merrill wrote: > On 12/18/18 3:45 PM, Jakub Jelinek wrote: > > The following testcase FAILs, because parsing creates a TREE_CONSTANT > > CONSTRUCTOR that contains CONST_DECL elts. cp_fold_r can handle that, > > but constexpr evaluation doesn't touch

Re: [C++ PATCH] Constexpr fold even some TREE_CONSTANT ctors (PR c++/87934)

2018-12-18 Thread Jason Merrill
On 12/18/18 3:45 PM, Jakub Jelinek wrote: The following testcase FAILs, because parsing creates a TREE_CONSTANT CONSTRUCTOR that contains CONST_DECL elts. cp_fold_r can handle that, but constexpr evaluation doesn't touch those CONSTRUCTORs. Fixed thusly, bootstrapped/regtested on x86_64-linux a

[C++ PATCH] Constexpr fold even some TREE_CONSTANT ctors (PR c++/87934)

2018-12-18 Thread Jakub Jelinek
Hi! The following testcase FAILs, because parsing creates a TREE_CONSTANT CONSTRUCTOR that contains CONST_DECL elts. cp_fold_r can handle that, but constexpr evaluation doesn't touch those CONSTRUCTORs. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2018-12-1