QDox
  1. QDox
  2. QDOX-184

Support Binary Literals (java7)

    Details

    • Type: Improvement Improvement
    • Status: Resolved Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0
    • Component/s: Parser
    • Labels:
      None
    • Number of attachments :
      0

      Description

      See http://mail.openjdk.java.net/pipermail/coin-dev/2009-March/000929.html for more details.

      Some examples:

      // An 8-bit 'byte' literal.
      byte aByte = (byte)0b00100001;
      
      // A 16-bit 'short' literal.
      short aShort = (short)0b1010000101000101;
      
      // Some 32-bit 'int' literals.
      int anInt1 = 0b10100001010001011010000101000101;
      int anInt2 = 0b101;
      int anInt3 = 0B101; // The B can be upper or lower case as per the x in
      "0x45".
      
      // A 64-bit 'long' literal. Note the "L" suffix, as would also be used
      // for a long in decimal, hexadecimal, or octal.
      long aLong =
      0b01010000101000101101000010100010110100001010001011010000101000101L;
      

        Activity

        Hide
        Robert Scholte added a comment -

        Fixed in rev. 1241

        Show
        Robert Scholte added a comment - Fixed in rev. 1241
        Robert Scholte made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 2.0 [ 15636 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Robert Scholte
            Reporter:
            Robert Scholte
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: