MoonBit sha256: provide simple sha256 hash algorithm.
// Copyright 2009 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.$ moon version --all
moon 0.1.20260110 (0e584ac 2026-01-10) ~/.moon/bin/moon
moonc v0.7.1+adb125543 (2026-01-10) ~/.moon/bin/moonc
moonrun 0.1.20260110 (0e584ac 2026-01-10) ~/.moon/bin/moonrun
moon-pilot 0.0.1-df92511 (2026-01-10) ~/.moon/bin/moon-pilotpub(open) trait HashFunc {
name(Self) -> String
write(Self, Byte) -> Unit
check_sum(Self) -> String
}type Digestfn gen_hmac(body : Bytes, client_secret : Bytes) -> String