[clang] Fix crash during template sema checking
authorGuillaume Chatelet <gchatelet@google.com>
Fri, 20 Mar 2020 15:23:49 +0000 (16:23 +0100)
committerGuillaume Chatelet <gchatelet@google.com>
Sat, 21 Mar 2020 11:42:06 +0000 (12:42 +0100)
commitd260a10d98dff6e34d081e570df1f7c0a50b9a73
tree2f3340027cf419f6ff360c51460c47c55a0b7571
parentf9a8650578dcd1358179798117aecab3e3c35176
[clang] Fix crash during template sema checking

Summary: If the size parameter of `__builtin_memcpy_inline` comes from an un-instantiated template parameter current code would crash.

Reviewers: efriedma, courbet

Subscribers: cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D76504
clang/lib/Sema/SemaChecking.cpp
clang/test/Sema/builtins-memcpy-inline.cpp [moved from clang/test/Sema/builtins-memcpy-inline.c with 86% similarity]