[PATCH] Improved error recovery for _Pragma

Hubert Tong hubert.reinterpretcast at gmail.com
Fri Mar 13 09:27:52 PDT 2015


The old code would have handled this okay:

  _Pragma(
  BAD_TOKEN
  )

At the same time, the case could have looked like this:

  _Pragma( void bar() {
    foo();
  }
  /**EOF**/

Both of these could be handled by using a matched parentheses approach: it eats the `_Pragma` in the first, and erases the rest of the file in the second (avoiding spurious messages following the `_Pragma`).


http://reviews.llvm.org/D8308

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the cfe-commits mailing list