[cfe-commits] r158390 - in /cfe/trunk: lib/AST/Expr.cpp lib/Lex/LiteralSupport.cpp lib/Sema/SemaChecking.cpp test/SemaCXX/format-strings-0x.cpp

Richard Smith richard at metafoo.co.uk
Tue Jun 12 23:57:20 PDT 2012


On Tue, Jun 12, 2012 at 11:41 PM, Sean Silva <silvas at purdue.edu> wrote:

> +  assert((Kind == StringLiteral::Ascii || Kind == StringLiteral::UTF8) &&
> +         "Only narrow string literals are currently supported");
>
> If a non-narrow string-literal is encountered with asserts off, will this
> just continue on and silently corrupt the rest of the compilation? Or will
> parsing the non-narrow string literal gracefully fail somewhere earlier in
> the pipeline?
>

This function should not be called in such a case. Clang code does not
typically attempt to recover after an assertion has failed.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120612/a47379b7/attachment.html>


More information about the cfe-commits mailing list