Details
Description
When a 3.x function .rb file contains calls to `def` they will end up in a place where they are not supposed to be. It is illegal to have such definitions (they used to work in 3.x because they ended up being methods on Object (i.e. it polluted every class in Ruby which is obviously horrible and unwanted).
From 6.0.0, legacy functions are loaded by a new loader and it should catch these illegal definitions and raise an error instead of causing other hard to understand errors. (Currently the methods are defined, but in a place where the legacy function later cannot find and call them).
In the rare case that 3.x functions with illegal constructs are used in such a way that the illegal constructs are only loaded but never called users that want to prevent errors from being raised by the new check can set --func3x_check to false.
Attachments
Issue Links
- is blocked by
-
PUP-9359 PUP-9294 fails to load valid 3.x function when it contains call to constant
-
- Closed
-
- relates to
-
PUP-9469 Remove the setting to turn off func 3x API validation
-
- Resolved
-
-
PUP-11472 Legacy function error does not include the source ref
-
- Resolved
-
-
PUP-9268 5.5.7 breaks custom function
-
- Closed
-
- links to