Tapestry 5
  1. Tapestry 5
  2. TAP5-905

Tapestry should support the full range of Unicode characters acceptible by Java as property names

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.2.0
    • Component/s: tapestry-core
    • Labels:
      None

      Description

      Valid java identifiers allows some special characters. So, a valid classes in java with properties such as número cannot be referenced from tapestry templates using the notation $

      {número}

      . The following patch fixes the problem:

          • ./tapestry-core/src/main/antlr/org/apache/tapestry5/internal/antlr/PropertyExpressionLexer.g~ 2009-10-22 18:48:23.000000000 -0500
          • ./tapestry-core/src/main/antlr/org/apache/tapestry5/internal/antlr/PropertyExpressionLexer.g 2009-10-22 17:13:19.000000000 -0500
            ***************
          • 91,97 ****
            THIS : T H I S;

      IDENTIFIER
      ! : LETTER (LETTER | DIGIT | '_')*;

      // The Safe Dereference operator understands not to de-reference through
      // a null.
      — 91,122 ----
      THIS : T H I S;

      IDENTIFIER
      ! : JAVA_ID_START (JAVA_ID_PART)*
      ! ;
      !
      ! fragment
      ! JAVA_ID_START
      ! : '\u0024'
      ! | '\u0041'..'\u005a'
      ! | '\u005f'
      ! | '\u0061'..'\u007a'
      ! | '\u00c0'..'\u00d6'
      ! | '\u00d8'..'\u00f6'
      ! | '\u00f8'..'\u00ff'
      ! | '\u0100'..'\u1fff'
      ! | '\u3040'..'\u318f'
      ! | '\u3300'..'\u337f'
      ! | '\u3400'..'\u3d2d'
      ! | '\u4e00'..'\u9fff'
      ! | '\uf900'..'\ufaff'
      ! ;
      !
      ! fragment
      ! JAVA_ID_PART
      ! : JAVA_ID_START
      ! | '\u0030'..'\u0039'
      ! ;
      !

      // The Safe Dereference operator understands not to de-reference through
      // a null.

      1. patch0.txt
        3 kB
        Manuel Sugawara

        Activity

        Howard M. Lewis Ship made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Assignee Howard M. Lewis Ship [ hlship ]
        Fix Version/s 5.2.0 [ 12314122 ]
        Resolution Fixed [ 1 ]
        Howard M. Lewis Ship made changes -
        Summary Properties should be any valid java identifier Tapestry should support the full range of Unicode characters acceptible by Java as property names
        Manuel Sugawara made changes -
        Field Original Value New Value
        Attachment patch0.txt [ 12423377 ]
        Manuel Sugawara created issue -

          People

          • Assignee:
            Howard M. Lewis Ship
            Reporter:
            Manuel Sugawara
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development