[vala/wip/effectfree: 2/8] codegen: Use lvalue of the assignment when emitting array add
- From: Luca Bruno <lucabru src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala/wip/effectfree: 2/8] codegen: Use lvalue of the assignment when emitting array add
- Date: Wed, 15 Jun 2011 14:55:08 +0000 (UTC)
commit 77975473064be9f6c8a777fc7e57f8bf8188c6cd
Author: Luca Bruno <lucabru src gnome org>
Date: Wed Jun 15 12:28:29 2011 +0200
codegen: Use lvalue of the assignment when emitting array add
codegen/valaccodearraymodule.vala | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/codegen/valaccodearraymodule.vala b/codegen/valaccodearraymodule.vala
index 18e38df..869741e 100644
--- a/codegen/valaccodearraymodule.vala
+++ b/codegen/valaccodearraymodule.vala
@@ -686,11 +686,11 @@ public class Vala.CCodeArrayModule : CCodeMethodCallModule {
var binary = (BinaryExpression) assignment.right;
- var array = binary.left;
+ var array = assignment.left;
var array_type = (ArrayType) array.value_type;
var element = binary.right;
- var array_var = assignment.left.symbol_reference;
+ var array_var = array.symbol_reference;
if (array_type.rank == 1 && array_var != null && array_var.is_internal_symbol ()
&& (array_var is LocalVariable || array_var is Field)) {
// valid array add
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]