From 319201152011567cfedfbcb950b5f79fec5ae6ed Mon Sep 17 00:00:00 2001 From: Terik23 Date: Sun, 9 Oct 2016 20:35:11 +0500 Subject: [PATCH] --- nameof.cpp | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/nameof.cpp b/nameof.cpp index 4b58665..bcaa77e 100644 --- a/nameof.cpp +++ b/nameof.cpp @@ -1,19 +1,10 @@ ///Used to obtain the string name of a variable. #define nameof_variable(name) template_nameof_variable(name, #name) +template const char* template_nameof_variable(const T& validate_type, const char* name) { return name; } -template -const char* template_nameof_variable(const T& validate_type, const char* name) -{ - return name; -} ///Used to obtain the string name of a type. #define nameof_type(name) template_nameof_type(#name) - -template -const char* template_nameof_type(const char* name) -{ - return name; -} +template const char* template_nameof_type(const char* name) { return name; } //example int test = 0;