]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_const_eval/eval.rs
query for describe_def
[rust.git] / src / librustc_const_eval / eval.rs
index 9470316c7e7e018799cc5677c4fed84f05842828..8b1aa0708807bc4284b8b7f8bad0c09840e7ec70 100644 (file)
@@ -68,7 +68,7 @@ pub fn lookup_const_by_id<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>,
             _ => Some((def_id, substs))
         }
     } else {
-        match tcx.sess.cstore.describe_def(def_id) {
+        match tcx.describe_def(def_id) {
             Some(Def::AssociatedConst(_)) => {
                 // As mentioned in the comments above for in-crate
                 // constants, we only try to find the expression for a