From 53b180a9383668246a152af41aec8f6e565904a4 Mon Sep 17 00:00:00 2001 From: lucy96chen <47800040+lucy96chen@users.noreply.github.com> Date: Wed, 12 Oct 2022 14:41:22 -0700 Subject: Add specialization args test (#2444) * Added specialization args test; small cleanup changes to slang-digest.h * Moved slang::Digest inside namespace Slang --- source/core/slang-digest.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'source/core') diff --git a/source/core/slang-digest.h b/source/core/slang-digest.h index d1bc80b40..47c0cd8f7 100644 --- a/source/core/slang-digest.h +++ b/source/core/slang-digest.h @@ -4,6 +4,8 @@ namespace Slang { + using slang::Digest; + // Wrapper struct that holds objects necessary for hashing. struct DigestBuilder { @@ -19,9 +21,11 @@ namespace Slang hashGen.update(&context, item); } - void finalize(slang::Digest* outHash) + Digest finalize() { - hashGen.finalize(&context, outHash); + Digest hash; + hashGen.finalize(&context, &hash); + return hash; } private: -- cgit v1.2.3