KernelBlock.zip_map: def of stelliferous@0.0.2.0 Import: import stelliferous@0.0.2.0/kernel_block.bend as KernelBlock Lines 7-14 of stelliferous@0.0.2.0/kernel_block.bend: https://jend.leeeet.dev/read.txt?path=stelliferous@0.0.2.0/kernel_block.bend&start_line=7&end_line=14 import Base # Static product composition also lifts an operation to any pair of elements. # Nesting this template gives wider products without another arithmetic kernel. def zip_map(~Element: Data,~Context: Data,~combine: Element -> Element -> Context -> Element, left: Twin,right: Twin,context: Context) -> Twin: Twin{left_first,left_second} = left Twin{right_first,right_second} = right +context = context Twin{combine(left_first,right_first,context),combine(left_second,right_second,context)} Uses (1): https://jend.leeeet.dev/definition.txt?path=stelliferous@0.0.2.0/kernel_block.bend&name=Twin