managed-commons / stab-language

Automatically exported from code.google.com/p/stab-language
Apache License 2.0
5 stars 3 forks source link

Cannot appy final to local variables #32

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The following code does not work:

  public class Main {

        public static void main(String[] args){
            final Integer[] buffer = new Integer[0x5];
            // OR
            final Integer i = 2;
        }
    }

cannot apply "final" to local variables

Original issue reported on code.google.com by ice.ta...@gmail.com on 5 Aug 2010 at 10:30

GoogleCodeExporter commented 9 years ago
The 'final' keyword in Java allows the usage of local variables from anonymous 
inner classes. In Stab, anonymous inner classes do not exist, so final 
variables are useless.

Original comment by stab.hac...@gmail.com on 7 Aug 2010 at 2:34