Core.next_word: def of bend-collections@1.0.0.0 Import: import bend-collections@1.0.0.0/src/crypto/sha/core.bend as Core Lines 69-77 of bend-collections@1.0.0.0/src/crypto/sha/core.bend: https://jend.leeeet.dev/read.txt?path=bend-collections@1.0.0.0/src/crypto/sha/core.bend&start_line=69&end_line=77 import Base # Schedule histories always contain at least 16 words. Destructuring that prefix # avoids four independent linked-list walks for every expanded word; the fallback # preserves the total behavior used by the universal refinement theorem. def next_word(+history: List<&2, U32>) -> U32: match history: case a <> b <> c <> d <> e <> f <> g <> h <> i <> j <> k <> l <> m <> n <> o <> (p <> rest): (small1(b) + g + small0(o) + p : U32) case _: next_word_slow(history) Uses (6): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.add https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/sha/core.bend&name=next_word_slow https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/sha/core.bend&name=small0 https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/crypto/sha/core.bend&name=small1