From 4b80395130946094a45279ede9ad6a627ff02b08 Mon Sep 17 00:00:00 2001 From: Xavier Noria Date: Wed, 16 Mar 2016 08:22:35 +0100 Subject: [PATCH] removes unreachable code This array literal cannot be reached. The previous begin either returns to the caller via the explicit return in the ensure block if all goes well, or else propagates whatever make the begin block abort execution. I have investigated the origin of this a bit. In the past the ensure block didn't have a return call, see for example c08547d. Later on the return was added in 4da4506, but the trailing literal was left there. --- activesupport/lib/active_support/dependencies.rb | 2 -- 1 file changed, 2 deletions(-) diff --git a/activesupport/lib/active_support/dependencies.rb b/activesupport/lib/active_support/dependencies.rb index 4880e5efd8..7c681092fa 100644 --- a/activesupport/lib/active_support/dependencies.rb +++ b/activesupport/lib/active_support/dependencies.rb @@ -668,8 +668,6 @@ def new_constants_in(*descs) new_constants.each { |c| remove_constant(c) }.clear end - - [] end # Convert the provided const desc to a qualified constant name (as a string). -- GitLab