1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2025-05-19 00:43:18 +02:00

pt-BR: Review new fuzzy entries after .po file refresh (#976)

* Added steps to configure Poedit properly

* Small adjustments

* Add link to Poedit

* Fix file formatting

* One. More. dprint. Fix.

* Normalizes pt-BR.po file format through Poedit
with line wrap.

* Fix typo.

* Fix fuzzy entries after .po file reformatting.

* Fix one code sample
This commit is contained in:
Henri Fontana 2023-07-14 11:34:09 -07:00 committed by GitHub
parent d891d0bb5e
commit 4d11d59247
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2,7 +2,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Comprehensive Rust 🦀\n" "Project-Id-Version: Comprehensive Rust 🦀\n"
"POT-Creation-Date: \n" "POT-Creation-Date: \n"
"PO-Revision-Date: 2023-07-12 22:18-0700\n" "PO-Revision-Date: 2023-07-13 16:10-0700\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
"Language: pt_BR\n" "Language: pt_BR\n"
@ -784,9 +784,8 @@ msgid "Using It"
msgstr "Usando o Cargo" msgstr "Usando o Cargo"
#: src/SUMMARY.md:243 #: src/SUMMARY.md:243
#, fuzzy
msgid "Exceptions" msgid "Exceptions"
msgstr "Funções" msgstr "Exceções"
#: src/SUMMARY.md:245 #: src/SUMMARY.md:245
msgid "Useful Crates" msgid "Useful Crates"
@ -2838,9 +2837,9 @@ msgid ""
" `unsafe` allows you to call functions such as `slice::get_unchecked`\n" " `unsafe` allows you to call functions such as `slice::get_unchecked`\n"
" which does not do bounds checking." " which does not do bounds checking."
msgstr "" msgstr ""
"* O estouro de números inteiros é definido por meio da _flag_ " "* O estouro de números inteiros é definido por meio da _flag_ [`overflow-"
"[`overflow-checks`](https://doc.rust-lang.org/rustc/codegen-options/index.htm" "checks`](https://doc.rust-lang.org/rustc/codegen-options/index.html#overflow-"
"l#overflow-checks)\n" "checks)\n"
"em tempo de compilação. Se habilitada, o programa causará um pânico (uma " "em tempo de compilação. Se habilitada, o programa causará um pânico (uma "
"falha controlada do programa). Caso contrário, será usada a semântica\n" "falha controlada do programa). Caso contrário, será usada a semântica\n"
" _wrap-around_. Por padrão, você obtém pânicos em modo de depuração (`cargo " " _wrap-around_. Por padrão, você obtém pânicos em modo de depuração (`cargo "
@ -4430,8 +4429,7 @@ msgid ""
"Globally-scoped names for values can be given with static variables and " "Globally-scoped names for values can be given with static variables and "
"constant definitions." "constant definitions."
msgstr "" msgstr ""
"Nomes com escopo global podem ser dados com variáveis estáticas e " "Nomes com escopo global podem ser dados com variáveis estáticas e constantes."
"constantes."
#: src/basic-syntax/static-and-const.md:5 #: src/basic-syntax/static-and-const.md:5
msgid "## `const`" msgid "## `const`"
@ -5566,8 +5564,8 @@ msgid ""
"struct Point(i32, i32);\n" "struct Point(i32, i32);\n"
"\n" "\n"
"fn main() {\n" "fn main() {\n"
" let p1 = Point(3, 4);\n"
" let p2 = p1;\n" " let p2 = p1;\n"
" let p1 = Point(3, 4);\n"
" println!(\"p1: {p1:?}\");\n" " println!(\"p1: {p1:?}\");\n"
" println!(\"p2: {p2:?}\");\n" " println!(\"p2: {p2:?}\");\n"
"}\n" "}\n"
@ -11065,8 +11063,9 @@ msgid ""
"(such as sorting or a binary tree)\n" "(such as sorting or a binary tree)\n"
"over the types used or stored." "over the types used or stored."
msgstr "" msgstr ""
"Rust oferece suporte a tipos genéricos, que permitem algoritmos ou estruturas " "Rust oferece suporte a tipos genéricos, que permitem algoritmos ou "
"de dados\n" "estruturas de dados\n"
" (como ordenação ou árvore binária)\n" " (como ordenação ou árvore binária)\n"
"abstrair os tipos de dados usados ou armazenados." "abstrair os tipos de dados usados ou armazenados."
@ -11079,7 +11078,6 @@ msgid "You can use generics to abstract over the concrete field type:"
msgstr "Você pode usar tipos genéricos para abstrair o tipo concreto do campo:" msgstr "Você pode usar tipos genéricos para abstrair o tipo concreto do campo:"
#: src/generics/data-types.md:5 #: src/generics/data-types.md:5
#, fuzzy
msgid "" msgid ""
"```rust,editable\n" "```rust,editable\n"
"#[derive(Debug)]\n" "#[derive(Debug)]\n"
@ -11095,6 +11093,13 @@ msgid ""
"}\n" "}\n"
"```" "```"
msgstr "" msgstr ""
"```rust,editable\n"
"#[derive(Debug)]\n"
"struct Ponto<T> {\n"
" x: T,\n"
" y: T,\n"
"}\n"
"\n"
"fn main() {\n" "fn main() {\n"
" let inteiro = Ponto { x: 5, y: 10 };\n" " let inteiro = Ponto { x: 5, y: 10 };\n"
" let real = Ponto { x: 1.0, y: 4.0 };\n" " let real = Ponto { x: 1.0, y: 4.0 };\n"
@ -11108,6 +11113,10 @@ msgid ""
"\n" "\n"
"* Fix the code to allow points that have elements of different types." "* Fix the code to allow points that have elements of different types."
msgstr "" msgstr ""
"* Tente declarar uma nova variável `let p = Ponto { x: 5, y: 10.0 };`.\n"
"\n"
"* Arrume o código para permitir pontos que tenham elementos de tipos "
"diferentes."
#: src/generics/methods.md:1 #: src/generics/methods.md:1
msgid "# Generic Methods" msgid "# Generic Methods"
@ -11189,7 +11198,6 @@ msgid "behaves as if you wrote"
msgstr "se comporta como se você tivesse escrito" msgstr "se comporta como se você tivesse escrito"
#: src/generics/monomorphization.md:14 #: src/generics/monomorphization.md:14
#, fuzzy
msgid "" msgid ""
"```rust,editable\n" "```rust,editable\n"
"enum Option_i32 {\n" "enum Option_i32 {\n"
@ -11208,6 +11216,17 @@ msgid ""
"}\n" "}\n"
"```" "```"
msgstr "" msgstr ""
"```rust,editable\n"
"enum Option_i32 {\n"
" Some(i32),\n"
" None,\n"
"}\n"
"\n"
"enum Option_f64 {\n"
" Some(f64),\n"
" None,\n"
"}\n"
"\n"
"fn main() {\n" "fn main() {\n"
" let inteiro = Option_i32::Some(5);\n" " let inteiro = Option_i32::Some(5);\n"
" let real = Option_f64::Some(5.0);\n" " let real = Option_f64::Some(5.0);\n"
@ -11233,7 +11252,7 @@ msgid ""
"Rust lets you abstract over types with traits. They're similar to interfaces:" "Rust lets you abstract over types with traits. They're similar to interfaces:"
msgstr "" msgstr ""
"Rust permite abstrair características dos tipos usando `trait`. Eles são " "Rust permite abstrair características dos tipos usando `trait`. Eles são "
"semelhantes às interfaces:" "semelhantes a interfaces:"
#: src/traits.md:5 #: src/traits.md:5
msgid "" msgid ""
@ -11274,6 +11293,41 @@ msgid ""
"}\n" "}\n"
"```" "```"
msgstr "" msgstr ""
"```rust,editable\n"
"trait Pet {\n"
" fn nome(&self) -> String;\n"
"}\n"
"\n"
"struct Cachorro {\n"
" nome: String,\n"
"}\n"
"\n"
"struct Gato;\n"
"\n"
"impl Pet for Cachorro {\n"
" fn nome(&self) -> String {\n"
" self.nome.clone()\n"
" }\n"
"}\n"
"\n"
"impl Pet for Gato {\n"
" fn nome(&self) -> String {\n"
" String::from(\"Gato\") // Sem nomes, gatos não respondem mesmo.\n"
" }\n"
"}\n"
"\n"
"fn saudar<P: Pet>(pet: &P) {\n"
" println!(\"Quem é? É o {}!\", pet.nome());\n"
"}\n"
"\n"
"fn main() {\n"
" let bidu = Cachorro { nome: \"Bidu\".into() };\n"
" saudar(&bidu);\n"
"\n"
" let felix = Gato;\n"
" saudar(&felix);\n"
"}\n"
"```"
#: src/traits/trait-objects.md:1 #: src/traits/trait-objects.md:1
msgid "# Trait Objects" msgid "# Trait Objects"
@ -11284,6 +11338,8 @@ msgid ""
"Trait objects allow for values of different types, for instance in a " "Trait objects allow for values of different types, for instance in a "
"collection:" "collection:"
msgstr "" msgstr ""
"Objetos `trait` permitem valores de diferentes tipos, por exemplo, em uma "
"coleção:"
#: src/traits/trait-objects.md:5 #: src/traits/trait-objects.md:5
msgid "" msgid ""
@ -11322,13 +11378,46 @@ msgid ""
"}\n" "}\n"
"```" "```"
msgstr "" msgstr ""
"```rust,editable\n"
"trait Pet {\n"
" fn nome(&self) -> String;\n"
"}\n"
"\n"
"struct Cachorro {\n"
" nome: String,\n"
"}\n"
"\n"
"struct Gato;\n"
"\n"
"impl Pet for Cachorro {\n"
" fn nome(&self) -> String {\n"
" self.nome.clone()\n"
" }\n"
"}\n"
"\n"
"impl Pet for Gato {\n"
" fn nome(&self) -> String {\n"
" String::from(\"O gato\") // Sem nomes, de qualquer forma gatos não "
"reconhecem.\n"
" }\n"
"}\n"
"\n"
"fn main() {\n"
" let pets: Vec<Box<dyn Pet>> = vec![\n"
" Box::new(Gato),\n"
" Box::new(Cachorro { nome: String::from(\"Bidu\") }),\n"
" ];\n"
" for pet in pets {\n"
" println!(\"Olá {}!\", pet.nome());\n"
" }\n"
"}\n"
"```"
#: src/traits/trait-objects.md:40 #: src/traits/trait-objects.md:40
msgid "Memory layout after allocating `pets`:" msgid "Memory layout after allocating `pets`:"
msgstr "Layout da memória após alocar `pets`:" msgstr "Layout da memória após alocar `pets`:"
#: src/traits/trait-objects.md:42 #: src/traits/trait-objects.md:42
#, fuzzy
msgid "" msgid ""
"```bob\n" "```bob\n"
" Stack Heap\n" " Stack Heap\n"
@ -11380,56 +11469,56 @@ msgid ""
"```" "```"
msgstr "" msgstr ""
"```bob\n" "```bob\n"
" Stack Heap\n" " Pilha Heap\n"
".- - - - - - - - - - - - - -. .- - - - - - - - - - - - - - - - - - - - - " ".- - - - - - - - - - - - - -. .- - - - - - - - - - - - - - - - - - - - - "
"- - -.\n" "- - -.\n"
": : : :\n" ": : : :\n"
": " ": "
"xs : : :\n" "pets : : :\n"
": +------------+-------+ : : +-----+-----" ": +-----------+-------+ : : +-----+-----"
"+ :\n" "+ :\n"
": | ponteiro | o---+--+-----+-->| o o | o o " ": | ptr | o---+---+-----+-->| o o | o o "
"| :\n" "| :\n"
": | tamanho | 2 | : : +-|-|-+-|-|-" ": | tamanho | 2 | : : +-|-|-+-|-|-"
"+ :\n" "+ :\n"
": | capacidade | 2 | : : | | | | +----+----+----" ": | capac. | 2 | : : | | | | +---------------"
"+ :\n" "+ :\n"
": +------------+-------+ : : | | | '-->| O | l | á " ": +-----------+-------+ : : | | | '-->| nome: \"Bidu\" "
"| :\n" "| :\n"
": : : | | | +----+----+----" ": : : | | | +---------------"
"+ :\n" "+ :\n"
"`- - - - - - - - - - - - - -' : | | " "`- - - - - - - - - - - - - -' : | | "
"| :\n" "| :\n"
" : | | | " " : | | | "
"+-------------------------+ :\n" "+--------------------------+ :\n"
" : | | '---->|\"<str as Display>::" " : | | '---->| \"<Cachorro as Pet>::"
"fmt\"| :\n" "nome\"| :\n"
" : | | " " : | | "
"+-------------------------+ :\n" "+--------------------------+ :\n"
" : | " " : | "
"| :\n" "| : \n"
" : | | +----+----+----+----" " : | | +-"
"+ :\n" "+ : \n"
" : | '-->| 7b | 00 | 00 | 00 " " : | '-->|"
"| :\n" "\\| : \n"
" : | +----+----+----+----" " : | +-"
"+ :\n" "+ : \n"
" : " " : "
"| :\n" "| : \n"
" : | +-------------------------" " : | +-----------------------"
"+ : \n"
" : '---->| \"<Gato as Pet>::nome\" "
"| : \n"
" : +-----------------------"
"+ :\n" "+ :\n"
" : '---->|\"<i32 as Display>::"
"fmt\"| :\n"
" : +-------------------------"
"+ :\n"
" : :\n"
" : :\n" " : :\n"
" '- - - - - - - - - - - - - - - - - - - - - " " '- - - - - - - - - - - - - - - - - - - - - "
"- - -'\n" "- - -'\n"
"\n"
"```" "```"
#: src/traits/trait-objects.md:72 #: src/traits/trait-objects.md:72
#, fuzzy
msgid "" msgid ""
"* Types that implement a given trait may be of different sizes. This makes " "* Types that implement a given trait may be of different sizes. This makes "
"it impossible to have things like `Vec<Pet>` in the example above.\n" "it impossible to have things like `Vec<Pet>` in the example above.\n"
@ -11449,22 +11538,27 @@ msgid ""
" println!(\"{}\", std::mem::size_of::<Box<dyn Pet>>());\n" " println!(\"{}\", std::mem::size_of::<Box<dyn Pet>>());\n"
" ```" " ```"
msgstr "" msgstr ""
"* _Traits_ podem especificar métodos pré-implementados (padrão) e métodos " "* Tipos que implementam um dado `trait` podem ter tamanhos diferentes. Isto "
"que os usuários devem implementar por conta própria. Os métodos com " "torna impossível haver coisas como `Vec<Pet>` no exemplo anterior.\n"
"implementações padrão podem contar com os métodos necessários.\n" "* `dyn Pet` é uma maneira de dizer ao compilador sobre um tipo de tamanho "
"* Os tipos que implementam uma determinada característica podem ser de " "dinâmico que implementa `Pet`.\n"
"tamanhos diferentes. Isso torna impossível ter coisas como `Vec<Greet>` no " "* No exemplo, `pets` possui *fat pointers* para objetos que implementam "
"exemplo acima.\n" "`Pet`. O *fat pointer* consiste em dois componentes, um ponteiro para o "
"* `dyn Greet` é uma maneira de dizer ao compilador sobre um tipo de tamanho " "objeto propriamente dito e um ponteiro para a tabela de métodos virtuais "
"dinâmico que implementa `Greet`.\n" "para a implementação de `Pet` do objeto em particular.\n"
"* No exemplo, `pets` mantém _Fat Pointers_ para objetos que implementam " "* Compare estas saídas no exemplo anterior::\n"
"`Greet`. O _Fat Pointer_ consiste em dois componentes, um ponteiro para o " " ```rust,ignore\n"
"objeto real e um ponteiro para a tabela de métodos virtuais para a " " println!(\"{} {}\", std::mem::size_of::<Cachorro>(), std::mem::"
"implementação de `Greet` desse objeto em particular." "size_of::<Gato>());\n"
" println!(\"{} {}\", std::mem::size_of::<&Cachorro>(), std::mem::"
"size_of::<&Gato>());\n"
" println!(\"{}\", std::mem::size_of::<&dyn Pet>());\n"
" println!(\"{}\", std::mem::size_of::<Box<dyn Pet>>());\n"
" ```"
#: src/traits/deriving-traits.md:1 #: src/traits/deriving-traits.md:1
msgid "# Deriving Traits" msgid "# Deriving Traits"
msgstr "# traits derivados" msgstr "# _Traits_ Derivados"
#: src/traits/deriving-traits.md:3 #: src/traits/deriving-traits.md:3
msgid "You can let the compiler derive a number of traits:" msgid "You can let the compiler derive a number of traits:"