grande mercado 😭 • Comunidade legal • Muito material disponível • Oportunidade de trabalhar com memory management, borrow checker, lifetimes, tipos expressivos • Aprender boas práticas de desenvolvimento com mensagens de erro • Not Haskell, but functional Programming and types • Not List, but Macros
• Guaranteed memory safe, no memory leak • Threads without data races • No runtime, no Garbage Collection • No undefined behaviour • Zero-cost abstractions • Ergonômica, developer happyness • Expressive data structures • Pattern matching • Type inference
é baseada em gambiarra • Fácil de escrever testes automatizados • Fácil de gerir dependências • Fácil de gerir projetos • De modo geral, Integração Contínua é muito mais fácil
is an important distinction to understand • Statements are instructions that perform some action and do not return a value ◦ Creating a variable and assigning a value to it with the let keyword ◦ Function definitions ◦ C and Ruby assignment returns the value of the assignment • Expressions evaluate to a resulting value ◦ the 6 in the statement let y = 6 ◦ Calling a function ◦ Calling a macro ◦ The block that we use to create new scopes, {} • Function bodies are made up of a series of statements optionally ending in an expression
Stack: Memory set aside for a thread • Ownership rules: ◦ Each value in Rust has a variable that's called its owner ◦ There can only be one owner at a time ◦ When the owner goes out of scope, the value will be dropped