Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Filesystem] Updated phpdoc on allowed types of content#20980
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
ro0NL commentedDec 18, 2016
| Q | A |
|---|---|
| Branch? | 2.7 |
| Bug fix? | no |
| New feature? | no |
| BC breaks? | no |
| Deprecations? | no |
| Tests pass? | yes |
| Fixed tickets | #20612 (comment) |
| License | MIT |
| Doc PR | symfony/symfony-docs#... |
chalasr commentedDec 18, 2016
I believe Status: reviewed |
ro0NL commentedDec 18, 2016
I think were good... this applies to |
nicolas-grekas commentedDec 28, 2016
Technically, this is right, but this is a contract change. I'm not sure we want to guarantee that it works for anything else but strings. |
nicolas-grekas commentedDec 28, 2016
That could even be considered a BC break if we read things strictly. |
xabbuh commentedDec 28, 2016
👎 for me. Making this change means that we have to support the other types too. Thus, moving away from |
ro0NL commentedDec 28, 2016 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Making it a behavior discussion then.. do we allow users to rely on itright now? edit: this would lead to |
…ays in dumpFile() and appendToFile() (thewilkybarkid)This PR was squashed before being merged into the 4.3-dev branch (closes#29661).Discussion----------[Filesystem] Support resources and deprecate using arrays in dumpFile() and appendToFile()| Q | A| ------------- | ---| Branch? | master| Bug fix? | no| New feature? | no| BC breaks? | no| Deprecations? | yes| Tests pass? | yes| Fixed tickets || License | MIT| Doc PR |Running PHPStan on my project picked up that passing a resource to `Filesystem::dumpFile()` didn't match the documented type.I found this has been discussed in#20980 and#28019, without a clear result. But, my reading is that only strings should be supported. While I think that not supporting streams makes this a lot less useful (and I'm going to switch away from it), this does need to be resolved. So, I've deprecated using arrays and resources.Commits-------0eaf9d2 [Filesystem] Support resources and deprecate using arrays in dumpFile() and appendToFile()