mirror of
https://github.com/vlang/v.git
synced 2025-09-10 07:47:20 -04:00
hash: add more methods to the hash.Hash interface, to match the ones in Go (#22001)
This commit is contained in:
parent
79ee4ae046
commit
258aed44fe
@ -4,11 +4,15 @@
|
|||||||
module hash
|
module hash
|
||||||
|
|
||||||
pub interface Hash {
|
pub interface Hash {
|
||||||
|
mut:
|
||||||
// Sum appends the current hash to b and returns the resulting array.
|
// Sum appends the current hash to b and returns the resulting array.
|
||||||
// It does not change the underlying hash state.
|
// It does not change the underlying hash state.
|
||||||
sum(b []u8) []u8
|
sum(b []u8) []u8
|
||||||
size() int
|
size() int
|
||||||
block_size() int
|
block_size() int
|
||||||
|
free()
|
||||||
|
reset()
|
||||||
|
write(p []u8) !int
|
||||||
}
|
}
|
||||||
|
|
||||||
interface Hash32er {
|
interface Hash32er {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user