We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Learn more about funding links in repositories.
Report abuse
1 parent e85746f commit 0906a88Copy full SHA for 0906a88
spec/std/weak_ref_spec.cr
@@ -79,5 +79,8 @@ describe WeakRef do
79
State.count(:weak_foo_ref).should be > 0
80
instances.select { |wr| wr.value.nil? }.size.should be > 0
81
instances[-1].value.should_not be_nil
82
+
83
+ # Use `last` to stop the variable from being optimised away in release mode.
84
+ last.to_s
85
end
86
0 commit comments