From: Juerg Billeter Date: Tue, 24 Jul 2007 15:38:41 +0000 (+0000) Subject: skip memory manager for VAPI files remove unnecessary code in X-Git-Tag: VALA_0_1_2~25 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=760d8a877421dede85b988a2573862a2f2dc3187;p=platform%2Fupstream%2Fvala.git skip memory manager for VAPI files remove unnecessary code in 2007-07-24 Juerg Billeter * vala/valamemorymanager.vala: skip memory manager for VAPI files * vala/valasemanticanalyzer.vala: remove unnecessary code in visit_creation_method svn path=/trunk/; revision=382 --- diff --git a/ChangeLog b/ChangeLog index beda221..485c254 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2007-07-24 Jürg Billeter + * vala/valamemorymanager.vala: skip memory manager for VAPI files + * vala/valasemanticanalyzer.vala: remove unnecessary code in + visit_creation_method + +2007-07-24 Jürg Billeter + * gobject/valaccodecompiler.vala, compiler/valacompiler.vala: add --cc and -X options to be able to specify custom command and options for the C compiler diff --git a/vala/valamemorymanager.vala b/vala/valamemorymanager.vala index b580ce2..ab4f776 100644 --- a/vala/valamemorymanager.vala +++ b/vala/valamemorymanager.vala @@ -62,7 +62,9 @@ public class Vala.MemoryManager : CodeVisitor { } public override void visit_source_file (SourceFile! source_file) { - source_file.accept_children (this); + if (!source_file.pkg) { + source_file.accept_children (this); + } } public override void visit_class (Class! cl) { diff --git a/vala/valasemanticanalyzer.vala b/vala/valasemanticanalyzer.vala index 58c9998..ea7b1b2 100644 --- a/vala/valasemanticanalyzer.vala +++ b/vala/valasemanticanalyzer.vala @@ -448,21 +448,9 @@ public class Vala.SemanticAnalyzer : CodeVisitor { current_return_type = up_method.return_type; } - if (current_symbol is Class) { - if (!(m is CreationMethod)) { - find_base_interface_method (m, (Class) current_symbol); - if (m.is_virtual || m.overrides) { - find_base_class_method (m, (Class) current_symbol); - if (m.base_method == null) { - Report.error (m.source_reference, "%s: no suitable method found to override".printf (m.get_full_name ())); - } - } - } - } else if (current_symbol is Struct) { - if (m.is_abstract || m.is_virtual || m.overrides) { - Report.error (m.source_reference, "A struct member `%s' cannot be marked as override, virtual, or abstract".printf (m.get_full_name ())); - return; - } + if (m.is_abstract || m.is_virtual || m.overrides) { + Report.error (m.source_reference, "The creation method `%s' cannot be marked as override, virtual, or abstract".printf (m.get_full_name ())); + return; } if (m.body != null && current_class != null) {