public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "jlquinn at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libgcj/15560] New: SimpleTimeZone doesn't handle on-or-before/after at ends of month
Date: Sat, 22 May 2004 08:45:00 -0000	[thread overview]
Message-ID: <20040521061746.15560.jlquinn@gcc.gnu.org> (raw)

If you define a rule that goes beyond the ends of the month, getOffset will give
incorrect results.  For example,

timezone.setEndRule(Calendar.SEPTEMBER, -6, -Calendar.TUESDAY, 43200000);

refers to the tuesday on or before September 6.  In 2004, this is actually
August 31.

off = tz.getOffset(GregorianCalendar.AD, 2004, Calendar.AUGUST, 31,
Calendar.TUESDAY, 45000000);

should occur after the end rule, but will return before it.

See mauve test gnu.testlet.java.util.SimpleTimeZone.check12 for this example.

-- 
           Summary: SimpleTimeZone doesn't handle on-or-before/after at ends
                    of month
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libgcj
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jlquinn at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu
                    dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=15560


             reply	other threads:[~2004-05-21  6:17 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-22  8:45 jlquinn at gcc dot gnu dot org [this message]
2004-05-22 14:58 ` [Bug libgcj/15560] " pinskia at gcc dot gnu dot org
2004-08-11 21:48 ` pinskia at gcc dot gnu dot org
2005-01-09 19:06 ` pinskia at gcc dot gnu dot org
2005-01-10 19:35 ` pinskia at gcc dot gnu dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040521061746.15560.jlquinn@gcc.gnu.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).