From 3b0d3f27a5548c4405d189fd4e54cd78bde5e0bc Mon Sep 17 00:00:00 2001 From: Alex Kitchens Date: Tue, 22 May 2018 16:30:05 -0500 Subject: [PATCH] Define a Cycle I wasn't clear on what a Cycle was when reading through the document. Defining it will be helpful for other readers not familiar with it as well. --- src/query.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/query.md b/src/query.md index 2c518ee5..d48b6e7e 100644 --- a/src/query.md +++ b/src/query.md @@ -47,6 +47,9 @@ let ty = tcx.type_of(some_def_id); ### Cycles between queries +A cycle is when a query becomes stuck in a loop e.g. query A generates query B +which generates query A again. + Currently, cycles during query execution should always result in a compilation error. Typically, they arise because of illegal programs that contain cyclic references they shouldn't (though sometimes they