| ▲ | wrs 9 hours ago | ||||||||||||||||
Yes. "`@reduce(.And, ...)` combines every boolean using `and` and returns a single boolean." If it's true (the common case here) then you proceed to look at the next 8 bytes. If it's false, you apply a @bitcast (turn the booleans into bits) and @ctz (find the first 0) to get the index of where it was false. | |||||||||||||||||
| ▲ | tapirl 7 hours ago | parent [-] | ||||||||||||||||
Maybe I'm wrong, but should it be @clz instead? | |||||||||||||||||
| |||||||||||||||||