You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Status quo as of this writing: If a function needs a safe wrapper in 8.1, but is natively safe from 8.2 onwards, then we generate a safe wrapper for 8.1 and a pass-through wrapper for 8.2 onwards
Question: should these pass-through wrappers be flagged as "deprecated", with a notice that people should just use the upstream function?
The text was updated successfully, but these errors were encountered:
Right now if we drop support for php8.1, then these "functions which have been safe since 8.2" will be detected as "has always been safe", and the pass-through wrappers will no longer be generated. But it shouldn't be too hard to check back as far as 8.1 looking for unsafe functions, even if we're only generating code for 8.2+ -- and in that case we'd simply generate pass-through wrappers for all supported versions.
My thinking for not marking these functions as deprecated is that if you're writing an app which needs to run on 8.3 and 8.4, then it would be annoying to see deprecation warnings in 8.4, but you can't do anything about it because you genuinely do need to use the Safe wrappers in 8.3.
A half-baked idea would be to have three states:
generate safe wrappers for unsafe functions
generate pass-through wrappers with no warning for functions which became safe recently
generate pass-through wrappers with a deprecation warning for functions which became safe a long time ago (ie, they are natively safe in all currently-supported versions of PHP)
Status quo as of this writing: If a function needs a safe wrapper in 8.1, but is natively safe from 8.2 onwards, then we generate a safe wrapper for 8.1 and a pass-through wrapper for 8.2 onwards
Question: should these pass-through wrappers be flagged as "deprecated", with a notice that people should just use the upstream function?
The text was updated successfully, but these errors were encountered: