2008-04-13 Jürg Billeter <j@bitron.ch>
+ * vala/valasemanticanalyzer.vala, vala/valasymbolresolver.vala:
+ fix issues when using non-null types
+
+2008-04-13 Jürg Billeter <j@bitron.ch>
+
* vala/valaparser.vala: deprecate construct as parameter modifier,
fixes bug 524138
var array_type = (ArrayType) collection_type;
element_data_type = array_type.element_type;
need_type_check = true;
- } else if (collection_type.compatible (glist_type) || collection_type.compatible (gslist_type)) {
+ } else if (collection_type.compatible (glist_type, false) || collection_type.compatible (gslist_type, false)) {
if (collection_type.get_type_arguments ().size > 0) {
element_data_type = (DataType) collection_type.get_type_arguments ().get (0);
need_type_check = true;
}
- } else if (iterable_type != null && collection_type.compatible (iterable_type)) {
+ } else if (iterable_type != null && collection_type.compatible (iterable_type, false)) {
stmt.iterator_variable_declarator = new VariableDeclarator ("%s_it".printf (stmt.variable_name));
stmt.iterator_variable_declarator.type_reference = new InterfaceType (iterator_type);
stmt.iterator_variable_declarator.type_reference.takes_ownership = true;
element_type.transfers_ownership = false;
element_type.is_ref = false;
element_type.is_out = false;
+ element_type.nullable = false;
+ element_type.requires_null_check = false;
type = new ArrayType (element_type, unresolved_type.array_rank, unresolved_type.source_reference);
type.add_type_argument (element_type);