[ 
https://issues.apache.org/jira/browse/LANG-1328?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15996553#comment-15996553
 ] 

Bruno P. Kinoshita commented on LANG-1328:
------------------------------------------

Hello  [[email protected]],

>The outcome will be "dormingo" instead of "dor" in Portugese (pt_PT)

Actually, with 3.3.2 or 3.5, I'm getting the following from using pretty much 
your code.

{code}
String s = FastDateFormat.getInstance("MMM", TimeZone.getDefault(), new 
Locale("pt", "pt")).format(1494115200);
System.out.println(s);
{code}

Gives me:

{noformat}
jan
{noformat}

As M is the month of the year, and MMM is the three letter abbreviation for it. 
In Portuguese, MMM -> jan is correct (janeiro abbreviated as jan).

Using EEE, with either 3.5 or 3.3.2:

{code}
String s = FastDateFormat.getInstance("EEE", TimeZone.getDefault(), new 
Locale("pt", "pt")).format(1494115200);
System.out.println(s);
{code}

Gives me:

{noformat}
Dom
{noformat}

Which is again correct, as Domingo gets correctly abbreviated as Dom.

> FastDateFormat does not support 'EEE' and 'MMM' abbreviations for PT_pt
> -----------------------------------------------------------------------
>
>                 Key: LANG-1328
>                 URL: https://issues.apache.org/jira/browse/LANG-1328
>             Project: Commons Lang
>          Issue Type: Bug
>    Affects Versions: 3.3.2
>         Environment: Android
>            Reporter: Pär Nils Amsen
>
> For the following statement:
> {code:java}
> FastDateFormat.getInstance("MMM", timeZone, new Locale("pt", 
> "pt")).format(1494115200);
> {code}
> The outcome will be "dormingo" instead of "dor" in Portugese (pt_PT). I 
> expect this to be a bug since the only reason for FastDateFormat to not 
> abbreviate the weekdays would be that Portugese does not allow it, not very 
> likely.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to