Skip to content

Commit

Permalink
rustc: Make report_cycle and CycleError private
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcrichton committed Aug 26, 2017
1 parent c77213d commit c766aa4
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/librustc/ty/maps.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.

use errors::DiagnosticBuilder;
use dep_graph::{DepConstructor, DepNode, DepNodeIndex};
use errors::{Diagnostic, DiagnosticBuilder};
use hir::def_id::{CrateNum, DefId, LOCAL_CRATE};
Expand Down Expand Up @@ -213,13 +212,13 @@ impl<M: QueryDescription> QueryMap<M> {
}
}

pub struct CycleError<'a, 'tcx: 'a> {
struct CycleError<'a, 'tcx: 'a> {
span: Span,
cycle: RefMut<'a, [(Span, Query<'tcx>)]>,
}

impl<'a, 'gcx, 'tcx> TyCtxt<'a, 'gcx, 'tcx> {
pub fn report_cycle(self, CycleError { span, cycle }: CycleError)
fn report_cycle(self, CycleError { span, cycle }: CycleError)
-> DiagnosticBuilder<'a>
{
// Subtle: release the refcell lock before invoking `describe()`
Expand Down

0 comments on commit c766aa4

Please sign in to comment.