The Rust programming language offers the rare and valuable combination of statically verified memory safety and low-level control. Imagine C++ but without dangling pointers, null pointer dereferences, leaks, or buffer overruns. With this practical guide, systems programmers will understand Rust’s rules clearly and economically. You’ll learn how to express programs that Rust can prove are free of a broad class of common errors.
Rust brings the benefits of an expressive modern type system to systems programming. Authors Jim Blandy and Jason Orendorff demonstrate how Rust’s features put programmers in control over memory consumption and processor use, combining predictable performance with memory safety and trustworthy concurrency.
You’ll learn:
How to write fast, safe, concurrent programs in Rust
Rust’s rules for managing memory efficiently, including ownership, borrowing, moves, and lifetimes
How to design interfaces that fit well into the Rust ecosystem
Rust’s all-purpose Cargo tool for building, testing, and managing Rust packages
High-level features like traits, generics, closures, and iterators that make Rust productive and flexible
Jim Blandy has been programming since 1981, and writing Free software since 1990. He has been the maintainer of GNU Emacs and GNU Guile, and a maintainer of GDB, the GNU Debugger. He is one of the original designers of the Subversion version control system. Jim now works on Firefox’s web developer tools for Mozilla.
You'veheardthatRustletsyouwritesafe,fase,concurrentprograms.Thisisthechapterwhereweshowyouhowit'sdone.We'llcoverthreewaystouseRustthreads:1.Fork-joinparallelism2.Channels3.Sharedmuatblestate
——引自第458页
Apanicisnotacrash.It’snotundefinedbehavior.It’smorelikeaRuntimeExceptioninJavaorastd::logic_errorinC++.Thebehavioriswell-defined;itjustshouldn’tbehappening.Panicissafe.Itdoesn’tviolateanyofRust’ssafetyrules;evenifyoumanagetopanicinthemiddleofastandardlibrarymethod,itwillneverleaveadanglingpointerorahalf-initializedvalueinmemory.TheideaisthatRustcatchestheinvalidarrayaccess,orwhateveritis,beforeanythingbadhappens.Itwouldbeunsafetoproceed,soRustunwindsthestack.Buttherestoftheprocesscancontinuerunning.Panicisperthread.Onethreadcanbepanickingwhileotherthreadsaregoingonabouttheirnormalbusiness.InChapter19,we’llshowhowaparentthreadcanfindoutwhenachildthrea...
——引自第1页
急症速查手册-写给急诊科医生的一本口袋书 本书特色 本书主要为您介绍一般急症、神经系统急症、心血管系统急症、呼吸系统急症、消化系统急症、泌尿系统急症、风湿免疫系...
法庭上的修辞-案件事实叙事研究 本书特色 刘燕编著的《法庭上的修辞--案件事实叙事研究》的主要目的,是在知识上推进作者对司法活动的认识,补充一个新的视角、建构一...
小儿药证直诀-中医传世经典诵读本 本书特色《小儿药证直诀(中医传世经典诵读本)》是我国 现存较早的儿科专*,该书成书于公元1119年。《小 儿药证直诀》书名是宋...
詹妮弗·内格尔(Jennifer Nagel),加拿大多伦多大学哲学教授,研究方向集中在知识、信念以及我们追踪自己和他人这些状态的能力上。另从事当代心理哲学研究...
珍珠囊补遗药性赋助读 本书特色 《历代中医师传读本:珍珠囊补遗药性赋助读》:历代中医在师承教育实践中形成的读本有它的独到之处,对今天中医药人才的培养,仍然具有补...
段琦,女,1944年生于上海。1966年毕业于北京大学生物系,1991年毕业于美国麦考米克神学院,并取得神学研究硕士学位。1999被评为中国社会科学院世界宗教研...
安迪·塔纳,是一位享有盛誉的纸资产专家、成功的企业家和投资者,著有《401(k)的乱局》一书。他在股票期权投资的关键技巧传授方面的能力广为人知。他在富爸爸公司担...
《新世纪诗典(第二季)》内容简介:《新世纪诗典》是诗人伊沙开设的微博诗歌荐评专栏,《新世纪诗典·第二季》包括了该栏目一年内
精彩摘录你来人间一趟你要看看太阳和你的心上人一起走在街上——引自第12页
作者简介香港作家张爱玲
中医学基础 本书特色 本教材遵循“中医要发展,教材要改革”,保障中医理论传统性系统性的原则,结合中药类专业学生知识结构的特点,对教材的内容进行了充实和优化,对中...
法律人的救赎 本书特色 “独角札丛”丛书作者以国内法学界卓有名望的法学家和崭露头角并颇具人望的青年法律学者组成,集中体现了法律人的法学悟思与人文情怀,或庄重,或...
《王孟英医案绎注》 内容简介 本书选取了清代名医、温病大家王孟英的医案验录约380余篇,并有近代医家石念祖对各医案的详细注释。分析病情,辨明病机,阐释诊治精髓,...
思维方式是在历史时空中经过反复运用、选择、凝聚和抽象的结果,并反过来成为引导人们行动的原则、规范和世界观。有关思维方式的理解和使用,一般都比较宽泛。作为以不同方...
中药药效质量学 本书特色 药物的价值是其疗效,保障药物疗效的重要手段之一是制订药物质量标准。现有的主要通过鉴别中药真伪的质量控制标准因为与疗效间缺乏紧密相关性,...
人类的财富载体经历了漫长的演变,从原始社会几乎没有载体,到后来发展出房屋、土地、农具、牲畜、衣物、珠宝、古董、艺术品、金银,再到债券、股票、基金、保险、期货等金...
◆ 畅销好莱坞15年的编剧经典,常年位居亚马逊剧本写作图书榜榜首◆ 在圈内与《故事》《电影剧本写作基础》并称“编剧三宝”,并被中国、美国等多国院校影视专业列入推...
作品目录作者的话序言第一章 19世纪美国城市化的出现第二章 现代城市规划的诞生:I第三章 现代城市规划的诞生:II第四章 美国的
李曼瑞,女,1997出生于陕西西安,就读于西北工业大学附属中学。16岁获得“新概念”作文大赛二等奖。17岁直接晋级创新作文大赛全国总决赛,并获得高中组一等奖。作...
高血压病中医独特疗法 目录 基础知识篇什么是血压血压是怎样形成的什么是脉压差什么是动态血压 什么是平均动脉压测量血压时的注意事项测量动态血压有哪些优点动态血压监...