From 1d21c8aa1cd08d2d0db34ad62045f754f189e4c9 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Thu, 19 Jul 2018 20:41:06 +0200 Subject: [PATCH] clarify conflusion --- ralf/_posts/2018-07-19-const.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ralf/_posts/2018-07-19-const.md b/ralf/_posts/2018-07-19-const.md index d93a6cd..f511b9f 100644 --- a/ralf/_posts/2018-07-19-const.md +++ b/ralf/_posts/2018-07-19-const.md @@ -228,6 +228,8 @@ I am not sure which effect that should or will have for promotion. ## Conclusion I have discussed the notions of CTFE determinism and CTFE correctness (which are properties of a CTFE engine like miri), as well as const safety (property of a piece of code) and const soundness (property of a type system). +In particular, I propose that *when type-checking safe code in const context, we guarantee that this code is const-safe*, i.e., that it will not hit a CTFE error (though panics are allowed, just like they are in "run-time" Rust code). + There are still plenty of open questions, in particular around the interaction of [`const fn` and traits](https://github.com/rust-lang/rust/issues/24111#issuecomment-311029471), but I hope this terminology is useful when having those discussions. Let the type systems guide us :) -- 2.30.2