Uploaded image for project: 'BlueJ'
  1. BlueJ
  2. BLUEJ-372

CodePad rejects some syntactically valid expressions that have non-void types

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Medium
    • Resolution: Done
    • Affects Version/s: 3.0.5
    • Fix Version/s: 3.0.6
    • Component/s: CodePad

      Description

      To reproduce the problem:

      1. Create a Random object in the CodePad.
      2. Drag it to the object bench (giving it a name)
      3. In the CodePad use the name given in the previous step to invoke a method, say getBoolean() as random2.getBoolean() for instance. This works fine, but....
      4. In the CodePad use the name given to the Random object on the object bench to invoke the getClass() method inherited from Object, e.g., random2.getClass(). CodePad complains "Error ";" expected". However, getClass() is not void -- it returns a Class object -- so this should not provoke a syntax error. Other methods inherited from Object, e.g., toString() don't provoke an error.

        Attachments

          Activity

            People

            • Assignee:
              davmac Davin McCall
              Reporter:
              external External via trac
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: