Method: Ikra::Symbolic::ArrayCommand#==

Defined in:
lib/symbolic/symbolic.rb

#==(other) ⇒ Object

Methods for equality and hash. These methods are required for comparing array commands for equality. This is necessary because every array command can also act as a type. Types must be comparable for equality.



225
226
227
228
229
230
231
232
233
234
# File 'lib/symbolic/symbolic.rb', line 225

def ==(other)
    # Important: ArrayCommands may be created over and over during type inference.
    # It is important that we compare values and not identities!
    
    return self.class == other.class &&
        block_size == other.block_size &&
        input == other.input &&
        keep == other.keep &&
        block_def_node == other.block_def_node
end