1 /* Copyright (C) 2020 IBM Corp. 2 * This program is Licensed under the Apache License, Version 2.0 3 * (the "License"); you may not use this file except in compliance 4 * with the License. You may obtain a copy of the License at 5 * http://www.apache.org/licenses/LICENSE-2.0 6 * Unless required by applicable law or agreed to in writing, software 7 * distributed under the License is distributed on an "AS IS" BASIS, 8 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 9 * See the License for the specific language governing permissions and 10 * limitations under the License. See accompanying LICENSE file. 11 */ 12 13 #ifndef HELIB_APIATTRIBUTES_H 14 #define HELIB_APIATTRIBUTES_H 15 16 /** 17 * @file api_attributes.h 18 * @brief Contains pre-processor macros 19 **/ 20 21 namespace helib { 22 23 #ifndef UNUSED 24 #if __clang__ || __GNUC__ 25 /** 26 * @brief Mark a parameter or function as not used. 27 * This suppresses the -Wunused related warnings. 28 **/ 29 #define UNUSED __attribute__((unused)) 30 #else 31 #define UNUSED 32 #endif 33 #endif 34 35 } // namespace helib 36 37 #endif // ifndef HELIB_APIATTRIBUTES_H 38