Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:85658 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 60340 invoked from network); 1 Apr 2015 19:19:54 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 1 Apr 2015 19:19:54 -0000 Authentication-Results: pb1.pair.com smtp.mail=danack@basereality.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=danack@basereality.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain basereality.com from 209.85.217.174 cause and error) X-PHP-List-Original-Sender: danack@basereality.com X-Host-Fingerprint: 209.85.217.174 mail-lb0-f174.google.com Received: from [209.85.217.174] ([209.85.217.174:34948] helo=mail-lb0-f174.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 80/47-21906-8D44C155 for ; Wed, 01 Apr 2015 14:19:53 -0500 Received: by lbdc10 with SMTP id c10so43657543lbd.2 for ; Wed, 01 Apr 2015 12:19:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=H4W1Fb0wfKwIuFGJi3a2dlzJ74yuCE5KEmt7gazgXPg=; b=cCKbBIR62/feNtEq4RO2DQLx0jJd3tIGr+mP1hGFywhNUFhsKEXVHQtusEThZMvA4J Ti3oL9laU/UiZtcNhhs/9qXktMgUeSoUZXLSX3jx0Kt6y1mo/B4xAq8ecAtWT4KWqlOi lR0a2RnJJH5rnyb7Gl+Ia9I9Deyx8uk5LNbmS/zB9ugUmuZvzRRxo2tGN92/xyposb2P OhAmGuV1HvfERKz45FXIEWyGTqvAITmP9LXnYsMXk4/W8HwXmAWKe9Fk11300OMO+txI ly5qLrOPI/wCEuwdb43ysG9k3LDO5V1IZlRVCefXhE02W3YS7HSe0hTlbmeE+ukHMaGG 8RFQ== X-Gm-Message-State: ALoCoQmIwTGEqAbDmLWhPU3+zIQPsgQ9k8GLVk29k7MdHi/16GN34sHYUDuECboeI0cxj+7WRcFE MIME-Version: 1.0 X-Received: by 10.112.14.106 with SMTP id o10mr36085181lbc.2.1427915989189; Wed, 01 Apr 2015 12:19:49 -0700 (PDT) Received: by 10.25.87.202 with HTTP; Wed, 1 Apr 2015 12:19:49 -0700 (PDT) X-Originating-IP: [78.144.121.114] In-Reply-To: <551C3876.5000004@mabe.berlin> References: <551C3876.5000004@mabe.berlin> Date: Wed, 1 Apr 2015 19:19:49 +0000 Message-ID: To: Marc Bennewitz Cc: "internals@lists.php.net" Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] Deprecate setlocale? From: danack@basereality.com (Dan Ackroyd) On 1 April 2015 at 18:27, Marc Bennewitz wrote: > > Functionality not related to locale should not be effected by this global This is issue is that that the locale affects all of the C library that use it, which includes printf(); > -> The following bug reports are valid bugs and should be resolved > https://bugs.php.net/bug.php?id=59571 - breaks Imagick For Imagick, the issue is that a SVG string was being generated with something like: sprintf(svg, "pos: %f %f", x, y); When the locale is set to a locale that uses commas for the decimal point, this generates an invalid SVG string. I don't believe there is any possible work around for this. If you know of one, please can you say it? > Functionality not related to locale should not be effected by this global > Basic PHP functions should be possible to be TS and therefore should > ignoring such global configuration else it's impossible to have a TS > version of PHP The global is held by the C libraries, not in PHP code. And yes, the implication of that is that setlocale can not be thread safe. cheers Dan