utf8ãã©ã°ãã§fat commaã使ãã¨å·¦è¾ºãdecodeããããã°(perl-5.10.2ã§ä¿®æ£äºå®)
id:miyagawa ããããTwitterã§æãã¦ããã£ããã¿ãTwitterã ãã§å®çµããã®ã¯ãã£ãããªãã®ã§ããã«æ¸ãã¦ããã
å ãã¿ã¯ãã¡ãã
matsuu | Net::Twitter/Net::Twitter::Liteææ°çã®encode/decodeå¨ãããããããutf8ãã©ã°ãã¨LWPã絡ãã¨ãããªãã¤ã¼ãããããã¦ãã¦ã®ãªã³ãã¬ã¼ãã§ããã ( 2009-08-27 00:14:01 ) | |
miyagawa | @matsuu 3.04005 ã§ãªãããã¯ããªãã§ããããupdate() ã«ã¯ decode ããã®ã渡ããªãã¨ã ãã§ãã ( 2009-08-27 00:15:31 ) | |
miyagawa | @matsuu åä½ãããããã¹ã¯ãªãããã¿ãã¦ããããã°å¯¾å¿ã§ãã¾ãããã ã Net::Twitter 3.x ã§ç´ããã®ã¯ã2.xã§ãã¾ãã¾åãã¦ããï¼utf8 ãã¤ãã渡ãã°ãªãã¨ãªãåãã¦ããï¼ã®ãæ£ããããã®ã§ããã©ã ( 2009-08-27 00:20:03 ) | |
matsuu | @miyagawa ããutf8ãã¤ãåã§éãã®ãæµåã§ããï¼ç§ã¯Net::Twitter::Liteã使ã£ã¦utf8ãã©ã°ä»ãã渡ãã¦ããã§ãããencode('utf-8')ãã¦ãé¨åããªããã°æ£ããåä½ãã¦ã¾ãã ( 2009-08-27 00:25:59 ) | |
miyagawa | @matsuu ããããã©ã°ã¤ãï¼ã¨ãã表ç¾ã¯ãã¾ããã ããããã¾ãããï¼ã§æ¸¡ãã®ãæ£ããã§ãã ( 2009-08-27 00:28:46 ) | |
matsuu | @miyagawa http://gist.github.com/175600 ããã§ã2ã¨4ãåãã¾ããã¢ã«ã¦ã³ãæ å ±ã¯å¤ãã¦ã¾ãã ( 2009-08-27 00:56:56 ) | |
matsuu | @miyagawa encodeãå¿ è¦ãªã®ã¯GETã®åã®query_formæã®ã¿ã§ããããï¼ ( 2009-08-27 01:15:37 ) | |
miyagawa | @matsuu ã²ãã£ã¨ã㦠update => "ãã¹ã" ã 'update', "ãã¹ã" ã«ããã¨åããããã¾ããï¼ utf8 ãã©ã°ã㧠fat comma ãã¤ããã¨å·¦è¾ºãdecodeãããç½ ãªãã§ãããNet::Twitterå´ã§å¯¾å¿ãããå¾®å¦ã£ãããã ( 2009-08-27 04:24:35 ) | |
miyagawa | @matsuu Net::Twitter ã§å¯¾å¿ããã®ã§ã¤ãã®ãªãªã¼ã¹ã§ããã¾ãããå½é¢ã¯ 'status' => 㨠quote ããã°ãããã¯ãã ( 2009-08-27 06:40:06 ) | |
matsuu | ããã¼ã¼ã¼ã¼ã¼ã¼ã¼ã¼ãç¥ããªãã£ãï¼utf8ãã©ã°ã SUCKS! ( 2009-08-27 08:09:34 ) | |
matsuu | @miyagawa ãããã¨ããããã¾ãã確ãã«åä½ãã¾ãããã¾ã ã¾ã ç§ã¯ä¿®è¡ã足ããªãããã§ãã ( 2009-08-27 08:11:07 ) | |
miyagawa | @matsuu fixed in perl5 git :) http://perl5.git.perl.org/perl.git/commit/eaf7a4d2 ( 2009-08-27 09:02:17 ) |
詳ããã¯#68812ãåç §ãã¨ã©ã®ã¤ã¾ãã
use strict; use utf8; my %foo = (a => 'b', c => 'd');
ã¨æ¸ãã®ã§ã¯ãªãã
use strict; use utf8; my %foo = ('a' => 'b', 'c' => 'd');
ã¨fat commaã®å·¦è¾ºãæååã§æ¸ãã®ãç¡é£ã§ãã
åè
use strict; use warnings; use utf8; use Devel::Peek; my (%w, %x, %y, %z); %w = (a => 1); %x = ('a' => 1); $y{a} = 1; $z{'a'} = 1; Dump(%w); Dump(%x); Dump(%y); Dump(%z);
ããã¯ãããªçµæã«ãªãã
SV = PV(0x71b0f0) at 0x75cd80 REFCNT = 1 FLAGS = (TEMP,POK,pPOK,UTF8) PV = 0x739cf0 "a"\0 [UTF8 "a"] CUR = 1 LEN = 8 SV = PVIV(0x71c0d0) at 0x75cd80 REFCNT = 1 FLAGS = (TEMP,POK,FAKE,READONLY,pPOK) IV = 3392050242 PV = 0x7674a8 "a" CUR = 1 LEN = 0 SV = PVIV(0x71c0d0) at 0x75cd80 REFCNT = 1 FLAGS = (TEMP,POK,FAKE,READONLY,pPOK) IV = 3392050242 PV = 0x7674a8 "a" CUR = 1 LEN = 0 SV = PVIV(0x71c0d0) at 0x75cd80 REFCNT = 1 FLAGS = (TEMP,POK,FAKE,READONLY,pPOK) IV = 3392050242 PV = 0x7674a8 "a" CUR = 1 LEN = 0
ããã¯ç´æã«åããããã