前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >【Rust日报】2023-02-08 Rustproofing Linux

【Rust日报】2023-02-08 Rustproofing Linux

作者头像
MikeLoveRust
发布2023-02-15 20:51:53
5270
发布2023-02-15 20:51:53
举报

Rust面向对象研究 - 封装

在本篇中,作者对面向对象做了初步的介绍,并用代码展示了Rust的基本封装方法。

https://www.thecodedmessage.com/posts/oop-1-encapsulation/

Rust面向对象研究 - 多态

在本篇中,作者对面向对象理论的第二根支柱——多态——进行了实践研究。

https://www.thecodedmessage.com/posts/oop-2-polymorphism/

sniffnet - Rust实现的网络监控工具

界面非常不错,现在发布了v1.1版,功能更加完整。

使用Rust为Python写扩展的9条原则

Bed-Reader(一个Py生物信息学库)的作者总结的经验教训,包含9条:

  1. Create a single repository containing both Rust and Python projects
  2. Use maturin & PyO3 to create Python-callable translator functions in Rust
  3. Have the Rust translator functions call “nice” Rust functions
  4. Preallocate memory in Python
  5. Translate nice Rust error handling into nice Python error handling
  6. Multithread with Rayon and ndarray::parallel, returning any errors
  7. Allow users to control the number of parallel threads
  8. Translate nice dynamically-type Python functions into nice Rust generic functions
  9. Create both Rust and Python tests

https://towardsdatascience.com/nine-rules-for-writing-python-extensions-in-rust-d35ea3a4ec29

Matrix 2.0 官方正在引入Rust

Matrix 就是那个 Fediverse 的聊天网络。之前的Home server - Synapse 是用python写的。现在准备一点一点分模块使用Rust进行性能优化。另外一个出现的地方是SDK,使用Rust替换了之前js实现的密码学的部分。

另外还有一个第三方的Home server实现是用Rust写的:https://conduit.rs

https://github.com/matrix-org/synapse

Rustproofing Linux

这是一个系列文章,基于Rust已进入Linux kernel。此团队将研究如何将C驱动迁移到Rust上来的最佳实践。当然在迁移过程中,也会对比采用Rust来写driver到底有什么优势。

文章有四篇,强烈建议阅读学习:

  • Part 1 – Leaking Addresses:https://research.nccgroup.com/2023/02/06/rustproofing-linux-part-1-4-leaking-addresses/
  • Part 2 – Race Conditions(待写)
  • Part 3 – Integer Overflows(待写)
  • Part 4 – Shared Memory(待写)

tui-rs 需要人接手维护

tui-rs 作者貌似跑路(不出现)了。大家在商讨如何接手推进的事情。

https://github.com/fdehau/tui-rs/issues/654

本文参与 腾讯云自媒体分享计划,分享自微信公众号。
原始发表:2023-02-08,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 Rust语言学习交流 微信公众号,前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体分享计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
目录
  • Rust面向对象研究 - 封装
  • Rust面向对象研究 - 多态
  • sniffnet - Rust实现的网络监控工具
  • 使用Rust为Python写扩展的9条原则
  • Matrix 2.0 官方正在引入Rust
  • Rustproofing Linux
  • tui-rs 需要人接手维护
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档