From 23a43d10f3926400631c02a9f6547d0e03c7ee8a Mon Sep 17 00:00:00 2001 From: Ben Wiederhake Date: Sat, 22 Aug 2020 21:11:21 +0200 Subject: [PATCH] LibCrypto: Don't cause errors when function unused Any (future) program that includes this header would fail to compile, because the private symbol 'kind_name' is defined, along with a bunch of code, but unused. A good way to see this is by #include'ing LibCrypto/ASN1/ASN1.h in an unrelated .cpp-file, for example Userland/md.cpp. No other headers seem to have this problem. --- Libraries/LibCrypto/ASN1/ASN1.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Libraries/LibCrypto/ASN1/ASN1.h b/Libraries/LibCrypto/ASN1/ASN1.h index 42429f1a7f..4c0ad50a6c 100644 --- a/Libraries/LibCrypto/ASN1/ASN1.h +++ b/Libraries/LibCrypto/ASN1/ASN1.h @@ -52,7 +52,7 @@ enum class Kind { SetOf }; -static StringView kind_name(Kind kind) +static inline StringView kind_name(Kind kind) { switch (kind) { case Kind::Eol: