~ubuntu-branches/ubuntu/vivid/vala/vivid

« back to all changes in this revision

Viewing changes to vala/valamemberaccess.vala

  • Committer: Bazaar Package Importer
  • Author(s): Sebastian Dröge
  • Date: 2010-07-28 07:58:01 UTC
  • mfrom: (1.5.5 upstream) (7.3.14 experimental)
  • Revision ID: james.westby@ubuntu.com-20100728075801-18u9cg5hv5oety6m
Tags: 0.9.4-1
New upstream development release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
166
166
        }
167
167
 
168
168
        public override bool is_constant () {
169
 
                if (symbol_reference is Constant || symbol_reference is EnumValue) {
 
169
                if (symbol_reference is Constant) {
170
170
                        return true;
171
171
                } else {
172
172
                        return false;
521
521
 
522
522
                        // do not allow access to fields of generic types
523
523
                        // if instance type does not specify type arguments
524
 
                        if (f.field_type is GenericType) {
 
524
                        if (f.variable_type is GenericType) {
525
525
                                generics = true;
526
526
                        }
527
527
                } else if (member is Method) {
574
574
                        // do not allow access to methods using generic type parameters
575
575
                        // if instance type does not specify type arguments
576
576
                        foreach (var param in m.get_parameters ()) {
577
 
                                var generic_type = param.parameter_type as GenericType;
 
577
                                var generic_type = param.variable_type as GenericType;
578
578
                                if (generic_type != null && generic_type.type_parameter.parent_symbol is TypeSymbol) {
579
579
                                        generics = true;
580
580
                                        break;
724
724
                        // implicit this access
725
725
                        if (instance && inner == null) {
726
726
                                inner = new MemberAccess (null, "this", source_reference);
727
 
                                inner.value_type = this_parameter.parameter_type.copy ();
 
727
                                inner.value_type = this_parameter.variable_type.copy ();
728
728
                                inner.symbol_reference = this_parameter;
729
729
                        }
730
730