https://bugs.kde.org/show_bug.cgi?id=431391

--- Comment #7 from David Redondo <k...@david-redondo.de> ---
(In reply to Milian Wolff from comment #6)
> can you try to call clang_getCanonicalType beforehand, and see if the issue
> persists? something like the following:
> 
> ```
> diff --git a/plugins/clang/duchain/builder.cpp
> b/plugins/clang/duchain/builder.cpp
> index 1024ca3100..796c7ce2dc 100644
> --- a/plugins/clang/duchain/builder.cpp
> +++ b/plugins/clang/duchain/builder.cpp
> @@ -928,6 +928,8 @@ void Visitor::setTypeSize(CXType type, AbstractType*
> kdevType) const
>  {
>      if (kdevType->whichType() == AbstractType::TypeFunction)
>          return;
> +
> +    type = clang_getCanonicalType(type);
>      if (type.kind == CXType_Elaborated)
>          return;
>  
> ```
> 
> If it persists, can you try to add CXType_Auto to the early return check and
> re-run the clang unit tests and see if it affects size information on lines
> like
> 
> ```
> auto foo = 4;
> ```

I could do that but sadly not judge the impact because with my self compiled
KDevelop I cannot reproduce this crash that happens with the system package.

Maybe the clang version makes a difference here as I build against clang 10? I 
will try to rebuild against 8 to see if I can reproduce the crash this way.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to