Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean whitespace #29168

Merged
merged 1 commit into from
Oct 20, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ Building the documentation requires building the compiler, so the above
details will apply. Once you have the compiler built, you can

```sh
$ make docs NO_REBUILD=1
$ make docs NO_REBUILD=1
```

To make sure you don’t re-build the compiler because you made a change
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ hello.rs:4 }
```

This [unfortunate error](https://github.com/rust-lang/rust/issues/22547) is
correct: documentation comments apply to the thing after them, and there's
correct: documentation comments apply to the thing after them, and there's
nothing after that last comment.

[rc-new]: https://doc.rust-lang.org/nightly/std/rc/struct.Rc.html#method.new
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/method-syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ kinds of things `foo` could be: `self` if it’s just a value on the stack,
`&self` if it’s a reference, and `&mut self` if it’s a mutable reference.
Because we took the `&self` parameter to `area`, we can use it just like any
other parameter. Because we know it’s a `Circle`, we can access the `radius`
just like we would with any other `struct`.
just like we would with any other `struct`.

We should default to using `&self`, as you should prefer borrowing over taking
ownership, as well as taking immutable references over mutable ones. Here’s an
Expand Down
2 changes: 1 addition & 1 deletion src/doc/trpl/mutability.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ philosophy, memory safety, and the mechanism by which Rust guarantees it, the

> You may have one or the other of these two kinds of borrows, but not both at
> the same time:
>
>
> * one or more references (`&T`) to a resource,
> * exactly one mutable reference (`&mut T`).

Expand Down
6 changes: 3 additions & 3 deletions src/doc/trpl/ownership.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ With that in mind, let’s learn about ownership.
# Ownership

[Variable bindings][bindings] have a property in Rust: they ‘have ownership’
of what they’re bound to. This means that when a binding goes out of scope,
of what they’re bound to. This means that when a binding goes out of scope,
Rust will free the bound resources. For example:

```rust
Expand Down Expand Up @@ -158,8 +158,8 @@ has no pointers to data somewhere else, copying it is a full copy.

All primitive types implement the `Copy` trait and their ownership is
therefore not moved like one would assume, following the ´ownership rules´.
To give an example, the two following snippets of code only compile because the
`i32` and `bool` types implement the `Copy` trait.
To give an example, the two following snippets of code only compile because the
`i32` and `bool` types implement the `Copy` trait.

```rust
fn main() {
Expand Down
6 changes: 3 additions & 3 deletions src/doc/trpl/references-and-borrowing.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ So when we add the curly braces:
```rust
let mut x = 5;

{
{
let y = &mut x; // -+ &mut borrow starts here
*y += 1; // |
} // -+ ... and ends here
Expand Down Expand Up @@ -306,7 +306,7 @@ which was invalid. For example:

```rust,ignore
let y: &i32;
{
{
let x = 5;
y = &x;
}
Expand All @@ -323,7 +323,7 @@ error: `x` does not live long enough
note: reference must be valid for the block suffix following statement 0 at
2:16...
let y: &i32;
{
{
let x = 5;
y = &x;
}
Expand Down
4 changes: 2 additions & 2 deletions src/doc/trpl/strings.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@ println!("");
This prints:

```text
229, 191, 160, 231, 138, 172, 227, 131, 143, 227, 131, 129, 229, 133, 172,
忠, 犬, ハ, チ, 公,
229, 191, 160, 231, 138, 172, 227, 131, 143, 227, 131, 129, 229, 133, 172,
忠, 犬, ハ, チ, 公,
```

As you can see, there are more bytes than `char`s.
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
# met:

# (1) Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# notice, this list of conditions and the following disclaimer.

# (2) Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# distribution.

# (3) The name of the author may not be used to
# endorse or promote products derived from this software without
Expand Down
20 changes: 10 additions & 10 deletions src/libbacktrace/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@
# met:

# (1) Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# notice, this list of conditions and the following disclaimer.

# (2) Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# distribution.

# (3) The name of the author may not be used to
# endorse or promote products derived from this software without
Expand Down Expand Up @@ -137,10 +137,10 @@ LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
$(LDFLAGS) -o $@
SOURCES = $(libbacktrace_la_SOURCES) $(EXTRA_libbacktrace_la_SOURCES) \
$(btest_SOURCES) $(stest_SOURCES)
MULTISRCTOP =
MULTIBUILDTOP =
MULTIDIRS =
MULTISUBDIR =
MULTISRCTOP =
MULTIBUILDTOP =
MULTIDIRS =
MULTISUBDIR =
MULTIDO = true
MULTICLEAN = true
am__can_run_installinfo = \
Expand Down Expand Up @@ -389,7 +389,7 @@ config.h: stamp-h1
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
cd $(top_builddir) && $(SHELL) ./config.status config.h
$(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
$(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
($(am__cd) $(top_srcdir) && $(AUTOHEADER))
rm -f stamp-h1
touch $@
Expand All @@ -407,7 +407,7 @@ clean-noinstLTLIBRARIES:
echo "rm -f \"$${dir}/so_locations\""; \
rm -f "$${dir}/so_locations"; \
done
libbacktrace.la: $(libbacktrace_la_OBJECTS) $(libbacktrace_la_DEPENDENCIES) $(EXTRA_libbacktrace_la_DEPENDENCIES)
libbacktrace.la: $(libbacktrace_la_OBJECTS) $(libbacktrace_la_DEPENDENCIES) $(EXTRA_libbacktrace_la_DEPENDENCIES)
$(LINK) $(libbacktrace_la_OBJECTS) $(libbacktrace_la_LIBADD) $(LIBS)

clean-checkPROGRAMS:
Expand All @@ -418,10 +418,10 @@ clean-checkPROGRAMS:
list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
echo " rm -f" $$list; \
rm -f $$list
btest$(EXEEXT): $(btest_OBJECTS) $(btest_DEPENDENCIES) $(EXTRA_btest_DEPENDENCIES)
btest$(EXEEXT): $(btest_OBJECTS) $(btest_DEPENDENCIES) $(EXTRA_btest_DEPENDENCIES)
@rm -f btest$(EXEEXT)
$(btest_LINK) $(btest_OBJECTS) $(btest_LDADD) $(LIBS)
stest$(EXEEXT): $(stest_OBJECTS) $(stest_DEPENDENCIES) $(EXTRA_stest_DEPENDENCIES)
stest$(EXEEXT): $(stest_OBJECTS) $(stest_DEPENDENCIES) $(EXTRA_stest_DEPENDENCIES)
@rm -f stest$(EXEEXT)
$(LINK) $(stest_OBJECTS) $(stest_LDADD) $(LIBS)

Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/atomic.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/backtrace-supported.h.in
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/backtrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/backtrace.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
6 changes: 3 additions & 3 deletions src/libbacktrace/btest.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down Expand Up @@ -460,7 +460,7 @@ f23 (int f1line, int f2line)
(unsigned int) bdata.index, j + 1);
bdata.failed = 1;
}
}
}

check ("test3", 0, all, f3line, "f23", &bdata.failed);
check ("test3", 1, all, f2line, "f22", &bdata.failed);
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
# met:

# (1) Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# notice, this list of conditions and the following disclaimer.

# (2) Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# distribution.

# (3) The name of the author may not be used to
# endorse or promote products derived from this software without
Expand Down
6 changes: 3 additions & 3 deletions src/libbacktrace/dwarf.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down Expand Up @@ -1246,7 +1246,7 @@ add_unit_ranges (struct backtrace_state *state, uintptr_t base_address,

static int
find_address_ranges (struct backtrace_state *state, uintptr_t base_address,
struct dwarf_buf *unit_buf,
struct dwarf_buf *unit_buf,
const unsigned char *dwarf_str, size_t dwarf_str_size,
const unsigned char *dwarf_ranges,
size_t dwarf_ranges_size,
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/elf.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/fileline.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/mmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/mmapio.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
4 changes: 2 additions & 2 deletions src/libbacktrace/nounwind.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@ modification, are permitted provided that the following conditions are
met:

(1) Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
notice, this list of conditions and the following disclaimer.

(2) Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the
distribution.
distribution.

(3) The name of the author may not be used to
endorse or promote products derived from this software without
Expand Down
Loading