Re: r305903 - Function with unparsed body is a definition

2017-08-05 Thread Serge Pavlov via cfe-commits
This problem is addressed by https://reviews.llvm.org/D36353. Thanks, --Serge 2017-08-05 8:44 GMT+07:00 Alexander Kornienko : > Thank you for the analysis! It would be nice if you could implement a > short term workaround to avoid crashes. Maybe Richard has ideas on what a > proper solution shou

Re: r305903 - Function with unparsed body is a definition

2017-08-04 Thread Alexander Kornienko via cfe-commits
Thank you for the analysis! It would be nice if you could implement a short term workaround to avoid crashes. Maybe Richard has ideas on what a proper solution should look like. On Wed, Aug 2, 2017 at 8:05 PM, Serge Pavlov wrote: > At first thank you for the nice test case. > > This crash is not

Re: r305903 - Function with unparsed body is a definition

2017-08-02 Thread Serge Pavlov via cfe-commits
At first thank you for the nice test case. This crash is not caused by r305903. The root cause is that instantiation of f is triggered when parse of f is not finished yet. This is the case just addressed by that change. The instantiation is requested by the code (https://github.com/llvm-mirro r/cl

Re: r305903 - Function with unparsed body is a definition

2017-08-01 Thread Serge Pavlov via cfe-commits
Yes, sure, I will investigate it. Thanks, --Serge 2017-08-01 21:32 GMT+07:00 Alexander Kornienko : > This change causes an assertion failure on valid code. Could you take a > look at fixing this? > > A reduced test case: > > $ cat /tmp/SemaTemplateInstantiateDecl-crash2.cpp > template > constex

Re: r305903 - Function with unparsed body is a definition

2017-08-01 Thread Alexander Kornienko via cfe-commits
This change causes an assertion failure on valid code. Could you take a look at fixing this? A reduced test case: $ cat /tmp/SemaTemplateInstantiateDecl-crash2.cpp template constexpr void f(T) { f(0); } $ clang -fsyntax-only -std=c++11 /tmp/SemaTemplateInstantiateDecl-crash2.cpp assert.h asser

r305903 - Function with unparsed body is a definition

2017-06-21 Thread Serge Pavlov via cfe-commits
Author: sepavloff Date: Wed Jun 21 07:46:57 2017 New Revision: 305903 URL: http://llvm.org/viewvc/llvm-project?rev=305903&view=rev Log: Function with unparsed body is a definition While a function body is being parsed, the function declaration is not considered as a definition because it does no