dmlc / dmlc/tl2cgen

[FEA] Add extern "C" to generated header, so it can be used from C++ programs

Open
#33 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
55
Forks
11
PR merge metrics
No merged PRs in 30d

Description

In order to call C libraries from C++, function definitions need to be warped by:

```
#ifdef __cplusplus
extern "C"{
#endif

// Funtion declaration...

#ifdef __cplusplus
}
#endif
```

Automatically adding those lines to the generated header would simplify using classifiers from C++ code

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.