From 5e1d35c63378a8e509287e49aca3566a08fdcf1d Mon Sep 17 00:00:00 2001 From: Paul Duncan Date: Mon, 29 Apr 2024 18:31:10 -0400 Subject: examples/06-all/all-fns.c: add sha3_backend() example --- examples/06-all/all-fns.c | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'examples/06-all/all-fns.c') diff --git a/examples/06-all/all-fns.c b/examples/06-all/all-fns.c index 1aea4d6..f533559 100644 --- a/examples/06-all/all-fns.c +++ b/examples/06-all/all-fns.c @@ -1489,6 +1489,16 @@ static void k12_xof_example(void) { ///! [k12_xof] } +static void sha3_backend_example(void) { + ///! [sha3_backend] + // get backend name + const char *backend = sha3_backend(); + + // print backend name to stdout + printf("%s: backend=%s\n", __func__, backend); + ///! [sha3_backend] +} + int main(void) { sha3_224_example(); sha3_224_absorb_example(); @@ -1543,6 +1553,7 @@ int main(void) { k12_once_example(); k12_custom_once_example(); k12_xof_example(); + sha3_backend_example(); return 0; } -- cgit v1.2.3