dynamic array: method "clear"
fix type check for dynamic array assignment