JNA does not support C++11?
JNA does not support C++11?
在Java上调用c_func()时,以下代码将终止。如果不使用元组,则不会发生这种情况。我猜JNA不支持C++11,因为它引入了元组类型。我的猜测正确吗?
C++代码
#include <tuple>
#include <map>
int c_func(){
static std::map< std::tuple<float, float, float>, float> mapOfTuple;
return 1;
}
Java代码
...
public interface CLibrary extends Library {
public static final String JNA_LIBRARY_NAME = "test";
...
}
public static void main(String[] args) {
c_func();
}
JNA工作在接口级别,而不是实现级别。它甚至不知道您在c_func
中使用了C++11。然而,您的C++函数可能依赖于C++11运行库,这可能是问题所在。
相关文章:
- MSVC是否支持C++11样式的属性而不是__declspec
- 创建LinkedList退出,返回代码为-11(SIGSEGV)
- 我可以将一个用clang c++11编译的对象与另一个用c++17编译的对象链接起来吗
- 继承:构造函数,初始化C++11中基类的类C数组成员
- 如何将模板转换为C++11之前的模板
- c++11评估顺序(未定义的行为)
- C++中的VLA,扩展名为std=C++11
- 代码在我的计算机上运行良好,但是在将其提交给coursera时遇到未知的信号11问题
- "类模板示例<int>;"语句对 C++11 是什么意思?
- this_thread::sleep_for和计时时钟之间的关系是否由C++11标准指定
- 如何使用lock_guard在c++11中实现scoped_lock功能
- C++11 中不同类型的对象的 std::array 的替代方案
- 为什么 -mmacosx-version-min=10.10 不阻止使用标记为从 10.11 开始的函数?
- 为什么我的C++代码中出现'Segmentation Fault: 11'行?
- Makefile c++11 support
- Emacs, cedet and c++/c++11 support
- RTTI support for C++11 ( _CPPRTTI and __GNUG__ )
- JNA does not support C++11?
- C++11 thread_pool, futures, promises support in gcc
- pahole C++11 support?