Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

c++ 模板代码阅读 #113

Open
starrysky425 opened this issue Jan 16, 2024 · 3 comments
Open

c++ 模板代码阅读 #113

starrysky425 opened this issue Jan 16, 2024 · 3 comments

Comments

@starrysky425
Copy link

说出来不怕丢人,这些c++ 模板代码都是一行行手搓的吗?阅读起来着实有点费劲

@mutouyun
Copy link
Owner

emm...当然是手搓的。。我注释确实写得少了点,重构分支里在反省了。。
你哪里有疑问?可以提出来我看看

@starrysky425
Copy link
Author

我看好像没有暴露操作系统的原始句柄,在实际使用中,ipc消息的接收一般都是放到事件循环中,绑定回调来完成的。我看demo好像也没有使用事件循环,大多都是使用sleep+标志来循环侦听

@mutouyun
Copy link
Owner

嗯,你这种方式是actor模型。目前master分支的ipc,通讯模型是csp模型,recv函数会堵塞等待消息到达。你说的sleep,比如send_recv里,是用来模拟发送间隔的。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants