Skip to content

[VarDumper] Move locale sniffing to dump() time #23574

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 19, 2017

Conversation

nicolas-grekas
Copy link
Member

@nicolas-grekas nicolas-grekas commented Jul 18, 2017

Q A
Branch? 2.7
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #23572
License MIT
Doc PR -

@nicolas-grekas nicolas-grekas added this to the 3.2 milestone Jul 18, 2017
@@ -121,6 +119,9 @@ public function setIndentPad($pad)
*/
public function dump(Data $data, $output = null)
{
$this->decimalPoint = strval(0.5);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sorry fabbot, but I really want strval here, to prevent any optim by opcache :)

@nicolas-grekas nicolas-grekas force-pushed the dump-locale branch 2 times, most recently from 2605cf0 to f77161b Compare July 18, 2017 15:38
@nicolas-grekas nicolas-grekas changed the base branch from 3.2 to 2.7 July 18, 2017 15:40
@nicolas-grekas nicolas-grekas modified the milestones: 2.7, 3.2 Jul 18, 2017
$this->decimalPoint = (string) 0.5;
$this->decimalPoint = $this->decimalPoint[1];
$this->decimalPoint = localeconv();
$this->decimalPoint = $this->decimalPoint['decimal_point'];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why keep the logic here as well? Can't we remove it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For BC, the property is protected.

@fabpot
Copy link
Member

fabpot commented Jul 19, 2017

Thank you @nicolas-grekas.

@fabpot fabpot merged commit eed8a51 into symfony:2.7 Jul 19, 2017
fabpot added a commit that referenced this pull request Jul 19, 2017
…rekas)

This PR was merged into the 2.7 branch.

Discussion
----------

[VarDumper] Move locale sniffing to dump() time

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #23572
| License       | MIT
| Doc PR        | -

Commits
-------

eed8a51 [VarDumper] Move locale sniffing to dump() time
@nicolas-grekas nicolas-grekas deleted the dump-locale branch July 19, 2017 07:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants