Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of mbed-dev by
mbed_preprocessor.h
00001 /** \addtogroup platform */ 00002 /** @{*/ 00003 /** 00004 * \defgroup platform_preprocessor preprocessor macros 00005 * @{ 00006 */ 00007 00008 /* mbed Microcontroller Library 00009 * Copyright (c) 2006-2013 ARM Limited 00010 * 00011 * Licensed under the Apache License, Version 2.0 (the "License"); 00012 * you may not use this file except in compliance with the License. 00013 * You may obtain a copy of the License at 00014 * 00015 * http://www.apache.org/licenses/LICENSE-2.0 00016 * 00017 * Unless required by applicable law or agreed to in writing, software 00018 * distributed under the License is distributed on an "AS IS" BASIS, 00019 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00020 * See the License for the specific language governing permissions and 00021 * limitations under the License. 00022 */ 00023 #ifndef MBED_PREPROCESSOR_H 00024 #define MBED_PREPROCESSOR_H 00025 00026 00027 /** MBED_CONCAT 00028 * Concatenate tokens together 00029 * 00030 * @note 00031 * Expands tokens before concatenation 00032 * 00033 * @code 00034 * // Creates a unique label based on the line number 00035 * int MBED_CONCAT(UNIQUE_LABEL_, __LINE__) = 1; 00036 * @endcode 00037 */ 00038 #define MBED_CONCAT(a, b) MBED_CONCAT_(a, b) 00039 #define MBED_CONCAT_(a, b) a##b 00040 00041 /** MBED_STRINGIFY 00042 * Converts tokens into strings 00043 * 00044 * @note 00045 * Expands tokens before stringification 00046 * 00047 * @code 00048 * // Creates a string based on the parameters 00049 * const char *c = MBED_STRINGIFY(This is a ridiculous way to create a string) 00050 * @endcode 00051 */ 00052 #define MBED_STRINGIFY(a) MBED_STRINGIFY_(a) 00053 #define MBED_STRINGIFY_(a) #a 00054 00055 00056 #endif 00057 00058 /** @}*/ 00059 /** @}*/
Generated on Tue Jul 12 2022 20:08:03 by
 1.7.2
 1.7.2 
    