@@ -12,7 +12,7 @@ msgid ""
1212msgstr ""
1313"Project-Id-Version :Python 3.11\n "
1414"Report-Msgid-Bugs-To :\n "
15- "POT-Creation-Date :2025-11-05 16:53 +0000\n "
15+ "POT-Creation-Date :2025-11-07 17:12 +0000\n "
1616"PO-Revision-Date :2025-09-22 16:49+0000\n "
1717"Last-Translator :Marcos Moraes, 2025\n "
1818"Language-Team :Portuguese (Brazil) (https://app.transifex.com/python-doc/ "
@@ -574,7 +574,7 @@ msgstr ""
574574"Em muitas plataformas chamar funções variádicas por meio do ctypes é "
575575"exatamente o mesmo que chamar funções com um número fixo de parâmetros. Em "
576576"algumas plataformas, em particular no ARM64 para plataformas Apple, a "
577- "convenção chamada para funções variádicas é diferente daquela usada para "
577+ "convençãode chamada para funções variádicas é diferente daquela usada para "
578578"funções regulares."
579579
580580#: ../../library/ctypes.rst:384
@@ -792,6 +792,8 @@ msgid ""
792792"Nested structures can also be initialized in the constructor in several "
793793"ways::"
794794msgstr ""
795+ "Estruturas aninhadas também podem ser inicializadas no construtor de várias "
796+ "maneiras::"
795797
796798#: ../../library/ctypes.rst:618
797799msgid ""
@@ -806,6 +808,11 @@ msgid ""
806808"guaranteed by the library to work in the general case. Unions and "
807809"structures with bit-fields should always be passed to functions by pointer."
808810msgstr ""
811+ "O :mod:`ctypes` não suporta passar uniões ou estruturas com campos de bits "
812+ "(bit-fields) para funções por valor. Embora isso possa funcionar em x86 de "
813+ "32 bits, não é garantido pela biblioteca que funcione no caso geral. Uniões "
814+ "e estruturas com campos de bits devem sempre ser passadas para funções por "
815+ "ponteiro."
809816
810817#: ../../library/ctypes.rst:638
811818msgid "Structure/union alignment and byte order"
@@ -831,7 +838,7 @@ msgstr ""
831838
832839#: ../../library/ctypes.rst:656
833840msgid "Bit fields in structures and unions"
834- msgstr ""
841+ msgstr "Campos de bit em estruturas e uniões "
835842
836843#: ../../library/ctypes.rst:658
837844msgid ""
@@ -849,32 +856,39 @@ msgid ""
849856"Arrays are sequences, containing a fixed number of instances of the same "
850857"type."
851858msgstr ""
859+ "Vetores são sequências, contendo um número fixo de instâncias do mesmo tipo."
852860
853861#: ../../library/ctypes.rst:680
854862msgid ""
855863"The recommended way to create array types is by multiplying a data type with "
856864"a positive integer::"
857865msgstr ""
866+ "A maneira recomendada de criar tipos vetor é multiplicando um tipo de dado "
867+ "por um inteiro positivo::"
858868
859869#: ../../library/ctypes.rst:685
860870msgid ""
861871"Here is an example of a somewhat artificial data type, a structure "
862872"containing 4 POINTs among other stuff::"
863873msgstr ""
874+ "Aqui está um exemplo de um tipo de dado um tanto artificial, uma estrutura "
875+ "contendo 4 POINTs entre outras coisas::"
864876
865877#: ../../library/ctypes.rst:701
866878msgid "Instances are created in the usual way, by calling the class::"
867- msgstr ""
879+ msgstr "Instâncias são criadas da maneira usual, chamando a classe:: "
868880
869881#: ../../library/ctypes.rst:707
870882msgid ""
871883"The above code print a series of ``0 0`` lines, because the array contents "
872884"is initialized to zeros."
873885msgstr ""
886+ "O código acima exibe uma série de linhas ``0 0``, pois o conteúdo do vetor é "
887+ "inicializado com zeros."
874888
875889#: ../../library/ctypes.rst:710
876890msgid "Initializers of the correct type can also be specified::"
877- msgstr ""
891+ msgstr "Inicializadores do tipo correto também podem ser especificados:: "
878892
879893#: ../../library/ctypes.rst:726
880894msgid "Pointers"
@@ -885,33 +899,43 @@ msgid ""
885899"Pointer instances are created by calling the :func:`pointer` function on a :"
886900"mod:`ctypes` type::"
887901msgstr ""
902+ "Instâncias de ponteiro são criadas chamando a função :func:`pointer` em um "
903+ "tipo :mod:`ctypes`::"
888904
889905#: ../../library/ctypes.rst:736
890906msgid ""
891907"Pointer instances have a :attr:`~_Pointer.contents` attribute which returns "
892908"the object to which the pointer points, the ``i`` object above::"
893909msgstr ""
910+ "Instâncias de ponteiros têm um atributo :attr:`~_Pointer.contents` que "
911+ "retorna o objeto para qual o ponteiro aponta, o objeto ``i`` acima::"
894912
895913#: ../../library/ctypes.rst:743
896914msgid ""
897915"Note that :mod:`ctypes` does not have OOR (original object return), it "
898916"constructs a new, equivalent object each time you retrieve an attribute::"
899917msgstr ""
918+ "Note que o :mod:`ctypes` não possui OOR (retorno de objeto original), ele "
919+ "constrói um objeto novo e equivalente cada vez que você recupera um "
920+ "atributo::"
900921
901922#: ../../library/ctypes.rst:752
902923msgid ""
903924"Assigning another :class:`c_int` instance to the pointer's contents "
904925"attribute would cause the pointer to point to the memory location where this "
905926"is stored::"
906927msgstr ""
928+ "Atribuir outra instância :class:`c_int` ao atributo do conteúdo do ponteiro "
929+ "faria com que o ponteiro apontasse para o local de memória onde ela está "
930+ "armazenada::"
907931
908932#: ../../library/ctypes.rst:764
909933msgid "Pointer instances can also be indexed with integers::"
910- msgstr ""
934+ msgstr "Instâncias de ponteiro também podem ser indexadas com inteiros:: "
911935
912936#: ../../library/ctypes.rst:770
913937msgid "Assigning to an integer index changes the pointed to value::"
914- msgstr ""
938+ msgstr "Atribuir a um índice inteiro altera o valor apontado:: "
915939
916940#: ../../library/ctypes.rst:779
917941msgid ""
@@ -921,6 +945,11 @@ msgid ""
921945"a C function, and you *know* that the pointer actually points to an array "
922946"instead of a single item."
923947msgstr ""
948+ "Também é possível usar índices diferentes de 0, mas você deve saber o que "
949+ "está fazendo, assim como em C: Você pode acessar ou alterar locais "
950+ "arbitrários da memória. Geralmente, você só usa este recurso se receber um "
951+ "ponteiro de uma função C, e você *sabe* que o ponteiro na verdade aponta "
952+ "para um vetor em vez de um único item."
924953
925954#: ../../library/ctypes.rst:785
926955msgid ""
@@ -929,18 +958,27 @@ msgid ""
929958"the :func:`POINTER` function, which accepts any :mod:`ctypes` type, and "
930959"returns a new type::"
931960msgstr ""
961+ "Nos bastidores, a função :func:`pointer` faz mais do que simplesmente criar "
962+ "instâncias de ponteiro, ela precisa criar *tipos* de ponteiro primeiro. Isso "
963+ "é feito com a função :func:`POINTER`, que aceita qualquer tipo :mod:"
964+ "`ctypes`, e retorna um novo tipo::"
932965
933966#: ../../library/ctypes.rst:801
934967msgid ""
935968"Calling the pointer type without an argument creates a ``NULL`` pointer. "
936969"``NULL`` pointers have a ``False`` boolean value::"
937970msgstr ""
971+ "Chamar o tipo ponteiro sem um argumento cria um ponteiro ``NULL``. Ponteiros "
972+ "``NULL`` possuem o valor booleano ``False``::"
938973
939974#: ../../library/ctypes.rst:809
940975msgid ""
941976":mod:`ctypes` checks for ``NULL`` when dereferencing pointers (but "
942977"dereferencing invalid non-\\ ``NULL`` pointers would crash Python)::"
943978msgstr ""
979+ "O :mod:`ctypes` verifica por ``NULL`` ao desreferenciar ponteiros (mas "
980+ "desreferenciar ponteiros inválidos que não sejam ``NULL`` travaria o "
981+ "Python)::"
944982
945983#: ../../library/ctypes.rst:828
946984msgid "Type conversions"
@@ -968,6 +1006,8 @@ msgstr ""
9681006#: ../../library/ctypes.rst:856
9691007msgid "To set a POINTER type field to ``NULL``, you can assign ``None``::"
9701008msgstr ""
1009+ "Para definir um campo do tipo PONTEIRO como ``NULL``, você pode atribuir "
1010+ "``None``::"
9711011
9721012#: ../../library/ctypes.rst:863
9731013msgid ""
@@ -977,6 +1017,11 @@ msgid ""
9771017"accepts ``POINTER(c_int)`` pointers or :class:`c_int` arrays for its "
9781018"``values`` field, but not instances of other types::"
9791019msgstr ""
1020+ "Às vezes, você tem instâncias de tipos incompatíveis. Em C, você pode "
1021+ "converter um tipo em outro tipo. O :mod:`ctypes` fornece uma função :func:"
1022+ "`cast` que pode ser usada da mesma maneira. A estrutura ``Bar`` definida "
1023+ "acima aceita ponteiros ``POINTER(c_int)`` ou vetores :class:`c_int` para seu "
1024+ "campo ``values``, mas não instâncias de outros tipos::"
9801025
9811026#: ../../library/ctypes.rst:875
9821027msgid "For these cases, the :func:`cast` function is handy."