Skip to content

Commit 83ad52a

Browse files
committed
fix: refine codes
1 parent 3a7d607 commit 83ad52a

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

core/include_internal/ten_rust/ten_rust.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ typedef struct MetricHandle MetricHandle;
1818
typedef struct ServiceHub ServiceHub;
1919
typedef struct ten_app_t ten_app_t;
2020

21+
#ifdef __cplusplus
22+
extern "C" {
23+
#endif
24+
2125
TEN_RUST_API void ten_rust_free_cstring(const char *ptr);
2226

2327
TEN_RUST_API Cipher *ten_cipher_create(const char *algorithm,
@@ -95,3 +99,7 @@ TEN_RUST_API void ten_metric_gauge_add(MetricHandle *metric_ptr, double value,
9599
TEN_RUST_API void ten_metric_gauge_sub(MetricHandle *metric_ptr, double value,
96100
const char *const *label_values_ptr,
97101
uintptr_t label_values_len);
102+
103+
#ifdef __cplusplus
104+
}
105+
#endif

0 commit comments

Comments
 (0)