Skip to content

Commit 205490b

Browse files
author
Alexander Regueiro
committed
Fixed nits raised in review.
1 parent 12d3ecb commit 205490b

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

src/bin/miri.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ fn find_sysroot() -> String {
178178
_ => {
179179
option_env!("RUST_SYSROOT")
180180
.expect(
181-
"could not find sysroot. either set `MIRI_SYSROOT` at run-time, or at \
181+
"could not find sysroot. Either set `MIRI_SYSROOT` at run-time, or at \
182182
build-time specify `RUST_SYSROOT` env var or use rustup or multirust",
183183
)
184184
.to_owned()

src/lib.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,7 @@ pub use crate::operator::EvalContextExt as OperatorEvalContextExt;
3939
pub use crate::intrinsic::EvalContextExt as IntrinsicEvalContextExt;
4040
pub use crate::tls::{EvalContextExt as TlsEvalContextExt, TlsData};
4141
use crate::range_map::RangeMap;
42-
// FIXME: rustc bug, issue <https://github.com/rust-lang/rust/issues/53682>.
43-
#[allow(unused_imports)]
42+
#[allow(unused_imports)] // FIXME: rustc bug, issue <https://github.com/rust-lang/rust/issues/53682>.
4443
pub use crate::helpers::{EvalContextExt as HelpersEvalContextExt};
4544
use crate::mono_hash_map::MonoHashMap;
4645
pub use crate::stacked_borrows::{EvalContextExt as StackedBorEvalContextExt};
@@ -129,7 +128,7 @@ pub fn create_ecx<'a, 'mir: 'a, 'tcx: 'mir>(
129128
let dest = ecx.eval_place(&mir::Place::Local(args.next().unwrap()))?;
130129
let argc = Scalar::from_uint(config.args.len() as u128, dest.layout.size);
131130
ecx.write_scalar(argc, dest)?;
132-
// Store argc for macOS: `_NSGetArgc`.
131+
// Store argc for macOS's `_NSGetArgc`.
133132
{
134133
let argc_place = ecx.allocate(dest.layout, MiriMemoryKind::Env.into());
135134
ecx.write_scalar(argc, argc_place.into())?;

src/range_map.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@ use rustc::ty::layout::Size;
1414

1515
#[derive(Clone, Debug)]
1616
struct Elem<T> {
17-
/// The range covered by this element, never empty.
17+
/// The range covered by this element; never empty.
1818
range: ops::Range<u64>,
19+
/// The data stored for this element.
1920
data: T,
2021
}
2122
#[derive(Clone, Debug)]
@@ -49,11 +50,11 @@ impl<T> RangeMap<T> {
4950
let candidate = left.checked_add(right).unwrap() / 2;
5051
let elem = &self.v[candidate];
5152
if offset < elem.range.start {
52-
// we are too far right (offset is further left)
53+
// We are too far right (offset is further left).
5354
debug_assert!(candidate < right); // we are making progress
5455
right = candidate;
5556
} else if offset >= elem.range.end {
56-
// we are too far left (offset is further right)
57+
// We are too far left (offset is further right).
5758
debug_assert!(candidate >= left); // we are making progress
5859
left = candidate+1;
5960
} else {

0 commit comments

Comments
 (0)