# sha3: define block_length as the rate, not as the state size \(\#14132\) · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/d86685ac9612c08e33f1d94f7f617d9c0da1b7bd)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: d86685ac9612c08e33f1d94f7f617d9c0da1b7bd

Requested commit: d86685ac9612c08e33f1d94f7f617d9c0da1b7bd

Commit: d86685ac9612c08e33f1d94f7f617d9c0da1b7bd

Tree: ebfd508ec57baa6df1f9ead511bf0c277728bcc8

Author: Frank Denis

Committer: GitHub

## Message

```
sha3: define block_length as the rate, not as the state size (#14132)

In sponge-based constructions, the block size is not the same as
the state size. For practical purposes, it's the same as the rate.

Size this is a constant for a given type, we don't need to keep
a copy of that value in the state itself. Just use the constant
directly. This saves some bytes and may even be slightly faster.

More importantly:
Fixes #14128
```

## Parents

- [e2d7b2bf339dac811b9ae77638f1d29b2ab32a23](https://git.cafe/gitcafe/zig/commit/e2d7b2bf339dac811b9ae77638f1d29b2ab32a23?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/d86685ac9612c08e33f1d94f7f617d9c0da1b7bd?format=markdown)
