[vala] Remove result variable warning
- From: Jürg Billeter <juergbi src gnome org>
- To: svn-commits-list gnome org
- Subject: [vala] Remove result variable warning
- Date: Fri, 10 Apr 2009 11:05:40 -0400 (EDT)
commit 157662d51ac2615b520d642664f1627b44233adc
Author: Jürg Billeter <j bitron ch>
Date: Fri Apr 10 16:16:19 2009 +0200
Remove result variable warning
Implicit result variable not planned for Vala 1.0.
---
vala/valalocalvariable.vala | 10 ----------
1 files changed, 0 insertions(+), 10 deletions(-)
diff --git a/vala/valalocalvariable.vala b/vala/valalocalvariable.vala
index 9fce2c2..7502551 100644
--- a/vala/valalocalvariable.vala
+++ b/vala/valalocalvariable.vala
@@ -142,16 +142,6 @@ public class Vala.LocalVariable : Symbol {
initializer.target_type = variable_type;
}
- if (name == "result") {
- // warn if type of `result' variable is incompatible with return type
- // as an implicit `result' variable might be introduced to be used
- // by Vala postconditions and implicit checks generated by the code generated
- if (analyzer.current_return_type == null
- || !variable_type.compatible (analyzer.current_return_type)) {
- Report.warning (source_reference, "result variable type incompatible with return type");
- }
- }
-
if (initializer != null) {
if (initializer.value_type == null) {
if (!(initializer is MemberAccess) && !(initializer is LambdaExpression)) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]