我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

如何从C ++ DLL回调GO方法

I have a GO program with a function that make a CGO call to c method defined in a dll. That part works great.. Now i need to make a callback from my dll to GO. Is that possible, any helping pointers ?

Note that my DLL code is separate codebase which gets compiled and linked separately to generate dll using visual studio. I'm on windows 10 64 bit machine.

I found exactly what i was looking for. Posting here so that it may help other with this problem.

https://github.com/golang/go/wiki/cgo#function-pointer-callbacks

近期文章

  • 带有AWS S3和goamz的Golang中不受支持的协议方案“”
  • 从Go中的列表中打印列表。 循环麻烦
  • 从数据库golang查询后接收304代码
  • 在goSublime中覆盖函数签名
  • 为什么`nbytes,err:= io.Copy(ioutil.Discard,resp.Body)`总是返回0?
  • 主管不写更多日志
  • “ go-vgo / robotgo”库构建错误
  • 将golang deepEqual接口{}转换为整数
  • 编组时间字段为Unix时间
  • 如何对Golang中的两个字符串数组进行XOR?
  • 复制一个html.Response,然后获取字符串
  • 从两个互斥体报告的数据竞争
  • 嵌套模板未呈现:Golang
  • 如何使用golang将图片上传到mongodb
  • Golang Kafka不消耗所有偏移量的最新消息
  • 从内部函数安全引用外部函数中的值?
  • Go语言中带有结果对象的动态结构
  • 将嵌套接口{}解组到用户提供的结构指针中
  • 使用golang从DynamoDB提取记录时出现紧急运行时错误
  • Go中的接口层次结构

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华