Skip to content

Commit b3df6fe

Browse files
DISTREATVexu
andcommitted
std.Progress: remove confusing comment
Co-authored-by: Veikka Tuominen <[email protected]>
1 parent c42dd44 commit b3df6fe

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/std/Progress.zig

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,8 @@ pub const Node = struct {
107107
}
108108

109109
/// Remove this `Node` from the `parent.children` stack of the provided `Node`. Thread-safe
110-
/// Returns void if `parent` is null
111110
fn tryRemoveFromParentStack(self: *Node, target_node: *Node) void {
112-
if (target_node.parent) |parent| {
111+
const parent = target_node.parent orelse return;
113112
self.context.update_mutex.lock();
114113
defer self.context.update_mutex.unlock();
115114
const index = std.mem.indexOfScalar(?*Node, parent.children[0..], self) orelse return;

0 commit comments

Comments
 (0)