提交 3967e1c9 编写于 作者: C Carlos Liam

Clean newlines

上级 2f60768e
......@@ -67,7 +67,7 @@ Read ["Installing Rust"] from [The Book].
```sh
# Update package mirrors (may be needed if you have a fresh install of MSYS2)
$ pacman -Sy pacman-mirrors
# Choose one based on platform:
$ pacman -S mingw-w64-i686-toolchain
$ pacman -S mingw-w64-x86_64-toolchain
......
......@@ -363,7 +363,7 @@ note: reference must be valid for the block suffix following statement 0 at
let y: &i32;
let x = 5;
y = &x;
println!("{}", y);
}
......@@ -371,7 +371,7 @@ note: ...but borrowed value is only valid for the block suffix following
statement 1 at 3:14
let x = 5;
y = &x;
println!("{}", y);
}
```
......
......@@ -6,7 +6,7 @@
* configure.ac: Add --enable-host-shared.
* configure: Regenerate.
Copyright (C) 2013-2014 Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification,
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -12,7 +12,7 @@
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# (3) The name of the author may not be used to
# endorse or promote products derived from this software without
# specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......@@ -1605,7 +1605,7 @@ read_line_header (struct backtrace_state *state, struct unit *u,
if (!advance (line_buf, hdrlen))
return 0;
hdr->min_insn_len = read_byte (&hdr_buf);
if (hdr->version < 4)
hdr->max_ops_per_insn = 1;
......@@ -1614,7 +1614,7 @@ read_line_header (struct backtrace_state *state, struct unit *u,
/* We don't care about default_is_stmt. */
read_byte (&hdr_buf);
hdr->line_base = read_sbyte (&hdr_buf);
hdr->line_range = read_byte (&hdr_buf);
......
......@@ -47,27 +47,27 @@
/* This file declares various DWARF-related constants using a set of
macros which can be redefined by the including file.
The macros are in sections. Each section corresponds to a single
set of DWARF constants and has a corresponding key. The key is
used in all the macro names.
The sections are TAG (for DW_TAG_ constants), FORM (DW_FORM_), AT
(DW_AT_), OP (DW_OP_), ATE (DW_ATE_), and CFA (DW_CFA_).
Using TAG as an example, the following macros may be used for each
key:
DW_FIRST_TAG(name, value) - Introduce the first DW_TAG constant.
DW_TAG(name, value) - Define a subsequent constant.
DW_TAG_DUP(name, value) - Define a subsequent constant whose value
is a duplicate of some other constant. Not all keys use the _DUP
macro form. If more than one name shares a value, then the base
(DW_TAG) form will be the preferred name and DW_TAG_DUP will hold
any alternate names.
DW_END_TAG - Invoked at the end of the DW_TAG constants. */
DW_FIRST_TAG (DW_TAG_padding, 0x00)
......
......@@ -352,7 +352,7 @@ enum dwarf_macro_record_type
DW_MACRO_GNU_lo_user = 0xe0,
DW_MACRO_GNU_hi_user = 0xff
};
/* @@@ For use with GNU frame unwind information. */
#define DW_EH_PE_absptr 0x00
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
......@@ -13,7 +13,7 @@ met:
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
(3) The name of the author may not be used to
endorse or promote products derived from this software without
specific prior written permission.
......
// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
......
// ignore-tidy-cr ignore-license
// ignore-tidy-cr (repeated again because of tidy bug)
// license is ignored because tidy can't handle the CRLF here properly.
// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
......@@ -11,33 +11,33 @@
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// NB: this file needs CRLF line endings. The .gitattributes file in
// this directory should enforce it.
// ignore-pretty
/// Doc comment that ends in CRLF
pub fn foo() {}
/** Block doc comment that
* contains CRLF characters
*/
pub fn bar() {}
fn main() {
let s = "string
literal";
assert_eq!(s, "string\nliteral");
let s = "literal with \
escaped newline";
assert_eq!(s, "literal with escaped newline");
let s = r"string
literal";
assert_eq!(s, "string\nliteral");
// validate that our source file has CRLF endings
let source = include_str!("lexer-crlf-line-endings-string-literal-doc-comment.rs");
assert!(source.contains("string\r\nliteral"));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册