Skip to content
Commit b455fc42 authored by Ilya Biryukov's avatar Ilya Biryukov
Browse files

[Preprocessor] Always discard body of #define if we failed to parse it

Summary:
Preivously we would only discard it if we failed to parse parameter lists.
If we do not consume the body, parser sees tokens inside directive. In
turn, this leads to spurious diagnostics and a crash in TokenBuffer, see
the added tests.

Reviewers: sammccall

Reviewed By: sammccall

Subscribers: cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D65517

llvm-svn: 367530
parent e5b5742e
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment