I’m aware that changing the environment with setfenv or reading from the environment with getfenv will disable LuaU optimizations, but does this apply when overriding global functions?
Example:
local OldPrint = print
function print(...)
OldPrint("Example", ...)
end