Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-808

Does not like untyped variables in classes

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.0-JSR-1
    • 1.0-JSR-2
    • class generator
    • None
    • Windows XP

    Description

      class SampleClass {
      firstField;
      secondField;

      public void SampleClass(String name)

      { firstField = name; }

      }

      When compiled, produces 'unexpected token, firstField'. adding

      @property firstField;

      or

      String firstField;

      solves the problem (but just produces an error for secondField);

      Attachments

        Activity

          People

            jstrachan James Strachan
            furashgf Gary Furash
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: