From 6b84ec54083da9911f5ad4816d0eb4f4745afad4 Mon Sep 17 00:00:00 2001 From: Jordan Augé Date: Mon, 7 Oct 2019 09:52:33 +0200 Subject: [HICN-298] Release new hICN app for Android MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I43adc62fadf00690b687078d739788dffdc5e566 Signed-off-by: Jordan Augé --- lib/includes/hicn/util/token.h | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 lib/includes/hicn/util/token.h (limited to 'lib/includes/hicn/util/token.h') diff --git a/lib/includes/hicn/util/token.h b/lib/includes/hicn/util/token.h new file mode 100644 index 000000000..43e0a77b2 --- /dev/null +++ b/lib/includes/hicn/util/token.h @@ -0,0 +1,40 @@ +/* + * Copyright (c) 2017-2019 Cisco and/or its affiliates. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/* Token concatenation */ + +/* + * Concatenate preprocessor tokens A and B without expanding macro definitions + * (however, if invoked from a macro, macro arguments are expanded). + */ +#define PPCAT_NX(A, B) A ## B + +/* + * Concatenate preprocessor tokens A and B after macro-expanding them. + */ +#define PPCAT(A, B) PPCAT_NX(A, B) + +/* Token stringification */ + +/* + * Turn A into a string literal without expanding macro definitions + * (however, if invoked from a macro, macro arguments are expanded). + */ +#define STRINGIZE_NX(A) #A + +/* + * Turn A into a string literal after macro-expanding it. + */ +#define STRINGIZE(A) STRINGIZE_NX(A) -- cgit 1.2.3-korg