mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-14 20:48:00 +00:00
[Objective-C API] WIgnore clang documentation warnings from C/C++ header usage. (#9057)
This commit is contained in:
parent
3ec3e9f705
commit
32366fea02
11 changed files with 38 additions and 21 deletions
28
objectivec/src/cxx_api.h
Normal file
28
objectivec/src/cxx_api.h
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
// Licensed under the MIT License.
|
||||
|
||||
// wrapper for ORT C/C++ API headers
|
||||
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
// ignore clang documentation-related warnings
|
||||
// instead, we will rely on Doxygen warnings for the C/C++ API headers
|
||||
#pragma clang diagnostic ignored "-Wdocumentation"
|
||||
#endif // defined(__clang__)
|
||||
|
||||
#include "onnxruntime_c_api.h"
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
|
||||
#if __has_include("coreml_provider_factory.h")
|
||||
#define ORT_OBJC_API_COREML_EP_AVAILABLE 1
|
||||
#else
|
||||
#define ORT_OBJC_API_COREML_EP_AVAILABLE 0
|
||||
#endif
|
||||
|
||||
#if ORT_OBJC_API_COREML_EP_AVAILABLE
|
||||
#include "coreml_provider_factory.h"
|
||||
#endif
|
||||
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif // defined(__clang__)
|
||||
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
#include <exception>
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
|
|
|
|||
|
|
@ -3,16 +3,7 @@
|
|||
|
||||
#import "ort_coreml_execution_provider.h"
|
||||
|
||||
#if __has_include("coreml_provider_factory.h")
|
||||
#define ORT_OBJC_API_COREML_EP_AVAILABLE 1
|
||||
#else
|
||||
#define ORT_OBJC_API_COREML_EP_AVAILABLE 0
|
||||
#endif
|
||||
|
||||
#if ORT_OBJC_API_COREML_EP_AVAILABLE
|
||||
#include "coreml_provider_factory.h"
|
||||
#endif
|
||||
|
||||
#import "src/cxx_api.h"
|
||||
#import "src/error_utils.h"
|
||||
#import "src/ort_session_internal.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
#include <algorithm>
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
namespace {
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
#import "ort_enums.h"
|
||||
|
||||
#include "onnxruntime_c_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
OrtLoggingLevel PublicToCAPILoggingLevel(ORTLoggingLevel logging_level);
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
#include <optional>
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
#import "src/error_utils.h"
|
||||
#import "src/ort_enums_internal.h"
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
#import "ort_env.h"
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
|
|
|
|||
|
|
@ -6,8 +6,7 @@
|
|||
#include <optional>
|
||||
#include <vector>
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
|
||||
#import "src/cxx_api.h"
|
||||
#import "src/error_utils.h"
|
||||
#import "src/ort_enums_internal.h"
|
||||
#import "src/ort_env_internal.h"
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
#import "ort_session.h"
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
|
|
|
|||
|
|
@ -7,8 +7,7 @@
|
|||
|
||||
#include "safeint/SafeInt.hpp"
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
|
||||
#import "src/cxx_api.h"
|
||||
#import "src/error_utils.h"
|
||||
#import "src/ort_enums_internal.h"
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
#import "ort_value.h"
|
||||
|
||||
#include "onnxruntime_cxx_api.h"
|
||||
#import "src/cxx_api.h"
|
||||
|
||||
NS_ASSUME_NONNULL_BEGIN
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue