summaryrefslogtreecommitdiffhomepage
path: root/ir/tr
diff options
context:
space:
mode:
authorChristoph Mallon <christoph.mallon@gmx.de>2016-04-29 18:51:03 +0200
committerChristoph Mallon <christoph.mallon@gmx.de>2016-04-29 18:51:03 +0200
commit598297989ce372a693b17e52943a02ec677e115c (patch)
tree085176d80aa1e4f574d17abebc6cbb0f8cfbbc8e /ir/tr
parent0b5c6b75d405e3988b5d7730db6bdc4c424b1e32 (diff)
tr: Reduce code duplication.
Diffstat (limited to 'ir/tr')
-rw-r--r--ir/tr/type.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/ir/tr/type.c b/ir/tr/type.c
index 2431ded..f3c5f669 100644
--- a/ir/tr/type.c
+++ b/ir/tr/type.c
@@ -812,8 +812,7 @@ ir_node *get_array_size(const ir_type *array)
unsigned get_array_size_int(const ir_type *array)
{
- assert(is_Array_type(array));
- ir_node *node = array->attr.array.size;
+ ir_node *const node = get_array_size(array);
return get_Const_long(node);
}