Skip to content

Commit a505e77

Browse files
RalfJungoli-obk
andcommitted
fix typos
Co-authored-by: Oliver Scherer <[email protected]>
1 parent d21e011 commit a505e77

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/librustc_mir/interpret/eval_context.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ pub struct Frame<'mir, 'tcx, Tag = (), Extra = ()> {
8484
// Current position within the function
8585
////////////////////////////////////////////////////////////////////////////////
8686
/// If this is `Err`, we are not currently executing any particular statement in
87-
/// this frame (can happen e.g. during frame initialziation, and during unwinding on
87+
/// this frame (can happen e.g. during frame initialization, and during unwinding on
8888
/// frames without cleanup code).
8989
/// We basically abuse `Result` as `Either`.
9090
pub(super) loc: Result<mir::Location, Span>,
@@ -663,7 +663,7 @@ impl<'mir, 'tcx: 'mir, M: Machine<'mir, 'tcx>> InterpCx<'mir, 'tcx, M> {
663663
let const_ =
664664
self.subst_from_current_frame_and_normalize_erasing_regions(const_.literal);
665665
self.const_to_op(const_, None).map_err(|err| {
666-
// If there was an error, set the span of the current frame so this constant.
666+
// If there was an error, set the span of the current frame to this constant.
667667
// Avoiding doing this when evaluation succeeds.
668668
self.frame_mut().loc = Err(span);
669669
err

src/librustc_mir/interpret/intrinsics/caller_location.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ impl<'mir, 'tcx: 'mir, M: Machine<'mir, 'tcx>> InterpCx<'mir, 'tcx, M> {
3030
// Assert that there is always such a frame.
3131
.unwrap();
3232
// Assert that the frame we look at is actually executing code currently
33-
// (`loc` is None when we are unwinding and the frame does not require cleanup).
33+
// (`loc` is `Err` when we are unwinding and the frame does not require cleanup).
3434
let loc = frame.loc.unwrap();
3535
// If this is a `Call` terminator, use the `fn_span` instead.
3636
let block = &frame.body.basic_blocks()[loc.block];

0 commit comments

Comments
 (0)