# 偷偷写日记......

## Reiko2/2/2021, 6:14:41 PM

👀👀👀👀👀👀

ice10004/19/2021, 12:05:32 AM

👀👀👀👀👀👀👀👀👀👀👀👀

ice10004/19/2021, 12:05:53 AM

# Elsewhere

## Chuigda_WhiteGive replied to 你们觉得 Rust 是如何解决 C++ 的哪些问题的？

n try_to_spawn() { let x: String = "5".to_string(); let j = thread::spawn(|| { println!("{}", x.len()); }); j.join().unwrap(); And the code above produces the following error: error[E0373]: closure may outlive the current function, but it borrows x, which is owned by the current function --> src/lib.rs:5:27 | | let j = thread::spawn(|| { | ^^ may outlive borrowed value x | println!("{}", x.len()); | - x is borrowed here |

elp: to force the closure to take ownership of x (and any other referenced variables), use the move keyword | | let j = thread::spawn(move || { | ^^^^ So as a result, you wrap almost everything with Arc to get 'static lifetime, wrap everything with Mutex/RwLock to achieve interior mutability. Again, you need unchecked unsafe kodes to achieve zero overhead. Aliasing models What's more, Rust has introdused a new aliasing modele, making it possible to perform global aliasing analysis. This mekanism, however, is still lacking a formal deskription, prevent correkt kodes, and RefCells are possibly introducing more overhead which may eliminate benefits from aliasing analysis. Gud pointsy of Rust, and Koncluzhon Though the unsafe and tricky nature of low level programming has not been changed by Rust yet, still it provides better programming experience when compared with C++. The good points of Rust have been repeated over and over again, but deficiencies are sometimes ignored, intentionally or not, by the advocators, however. Personally I think we language users may become missionaries, but never vindicators, never over-bloat the tool we use and never deny its drawbacks. Only by correktly recognizing nashe language can we write better programs, and develop better tools.

## Chuigda_WhiteGive replied to 你们懂 Linux 内核吗？

APUE关Linux内核屁事，APUE是关于posix的

I wonder too

## Reiko replied to Local Thermal Equilibrium翻译到场论中对应什么条件

density matrix是一个整体对state的描述，LTE是否应该翻译成reduced density matrix接近有限温度density matrix