From 907df8c0f7fd5ce07495010d3c0dd112f825d2fe Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Sun, 15 Apr 2018 13:28:15 +0200 Subject: Add a tracking issue for making the warning a lint --- src/librustc_mir/interpret/step.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/librustc_mir/interpret/step.rs b/src/librustc_mir/interpret/step.rs index f891d2b8ccb..554d87a04e2 100644 --- a/src/librustc_mir/interpret/step.rs +++ b/src/librustc_mir/interpret/step.rs @@ -11,6 +11,7 @@ impl<'a, 'mir, 'tcx, M: Machine<'mir, 'tcx>> EvalContext<'a, 'mir, 'tcx, M> { pub fn inc_step_counter_and_check_limit(&mut self, n: usize) { self.terminators_remaining = self.terminators_remaining.saturating_sub(n); if self.terminators_remaining == 0 { + // FIXME(#49980): make this warning a lint self.tcx.sess.span_warn(self.frame().span, "Constant evaluating a complex constant, this might take some time"); self.terminators_remaining = 1_000_000; } -- cgit 1.4.1-3-g733a5