Stabilize C string literals
This commit is contained in:
parent
a395214a3a
commit
0f41bc21b9
19 changed files with 41 additions and 90 deletions
|
@ -19,8 +19,8 @@ fn invalid_type_err(
|
|||
let snippet = cx.sess.source_map().span_to_snippet(span).ok();
|
||||
match ast::LitKind::from_token_lit(token_lit) {
|
||||
Ok(ast::LitKind::CStr(_, _)) => {
|
||||
// FIXME(c_str_literals): should concatenation of C string literals
|
||||
// include the null bytes in the end?
|
||||
// Avoid ambiguity in handling of terminal `NUL` by refusing to
|
||||
// concatenate C string literals as bytes.
|
||||
cx.emit_err(errors::ConcatCStrLit { span: span });
|
||||
}
|
||||
Ok(ast::LitKind::Char(_)) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue