Class: Kumi::IR::DF::Ops::ImportCall

Inherits:
Node show all
Defined in:
lib/kumi/ir/df/ops/import_call.rb

Instance Attribute Summary

Attributes inherited from Base::Instruction

#attributes, #axes, #dtype, #effects, #inputs, #metadata, #opcode, #result

Instance Method Summary collapse

Methods inherited from Node

opcode, #to_h

Methods inherited from Base::Instruction

#control_effect?, #defs, #effectful?, #io_effect?, #memory_effect?, #normalized_attributes, #printer_attributes, #printer_axes, #printer_dtype, #produces?, #stamp, #state_effect?, #to_h, #to_print_string, #uses, #validate!, #value_signature, #with_metadata

Constructor Details

#initialize(fn_name:, source_module:, args:, mapping_keys:, **kwargs) ⇒ ImportCall

Returns a new instance of ImportCall.



10
11
12
13
14
15
16
17
18
19
20
# File 'lib/kumi/ir/df/ops/import_call.rb', line 10

def initialize(fn_name:, source_module:, args:, mapping_keys:, **kwargs)
  super(
    inputs: Array(args),
    attributes: {
      fn_name: fn_name.to_sym,
      source_module: source_module.to_s,
      mapping_keys: Array(mapping_keys).map(&:to_sym)
    },
    **kwargs
  )
end