From 06909f182151cf2332a14909e8b772ab4648854e Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Mon, 5 Sep 2022 01:30:58 +0300 Subject: fix(tvix/eval): fix doc comment syntax where applicable As pointed out by grfn on cl/6091 Change-Id: I28308577b7cf99dffb4a4fd3cc8783eb9ab4d0d6 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6460 Tested-by: BuildkiteCI Reviewed-by: sterni --- tvix/eval/src/compiler/scope.rs | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'tvix/eval/src/compiler/scope.rs') diff --git a/tvix/eval/src/compiler/scope.rs b/tvix/eval/src/compiler/scope.rs index a7791b750af0..b6fa61e7759b 100644 --- a/tvix/eval/src/compiler/scope.rs +++ b/tvix/eval/src/compiler/scope.rs @@ -32,25 +32,25 @@ enum LocalName { /// Represents a single local already known to the compiler. #[derive(Debug)] pub struct Local { - // Identifier of this local. This is always a statically known - // value (Nix does not allow dynamic identifier names in locals), - // or a "phantom" value not accessible by users. + /// Identifier of this local. This is always a statically known + /// value (Nix does not allow dynamic identifier names in locals), + /// or a "phantom" value not accessible by users. name: LocalName, - // Source span at which this local was declared. + /// Source span at which this local was declared. pub span: codemap::Span, - // Scope depth of this local. + /// Scope depth of this local. pub depth: usize, - // Is this local initialised? + /// Is this local initialised? pub initialised: bool, - // Is this local known to have been used at all? + /// Is this local known to have been used at all? pub used: bool, - // Does this local need to be finalised after the enclosing scope - // is completely constructed? + /// Does this local need to be finalised after the enclosing scope + /// is completely constructed? pub needs_finaliser: bool, } @@ -135,18 +135,18 @@ pub struct Scope { pub locals: Vec, pub upvalues: Vec, - // How many scopes "deep" are these locals? + /// How many scopes "deep" are these locals? pub scope_depth: usize, - // Current size of the `with`-stack at runtime. + /// Current size of the `with`-stack at runtime. with_stack_size: usize, - // Users are allowed to override globally defined symbols like - // `true`, `false` or `null` in scopes. We call this "scope - // poisoning", as it requires runtime resolution of those tokens. - // - // To support this efficiently, the depth at which a poisoning - // occured is tracked here. + /// Users are allowed to override globally defined symbols like + /// `true`, `false` or `null` in scopes. We call this "scope + /// poisoning", as it requires runtime resolution of those tokens. + /// + /// To support this efficiently, the depth at which a poisoning + /// occured is tracked here. poisoned_tokens: HashMap<&'static str, usize>, } -- cgit 1.4.1