{"type": "func", "start": 6442724480, "end": 6442724594, "name": "fmt::internal::PrintfParser<wchar_t>::HandleArgIndex", "pseudocode": "// \n// fmt::internal::PrintfParser<wchar_t>::HandleArgIndex from 0x180042c80 to 0x180042cf2 (114 bytes)\n// \n// 1 xrefs:\n// > <???> @ 0x1801438a8\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\n// Alternative name is '?HandleArgIndex@?$PrintfParser@D@internal@fmt@@AEAAAEBUArg@23@IAEAPEBD@Z'\nvoid *__fastcall fmt::internal::PrintfParser<wchar_t>::HandleArgIndex(__int64 a1, unsigned int a2, const char **a3)\n{\n  int v3; // eax\n  const char *v4; // rax\n\n  v3 = *(_DWORD *)(a1 + 16);\n  if ( a2 == -1 )\n  {\n    if ( v3 >= 0 )\n    {\n      a2 = *(_DWORD *)(a1 + 16);\n      *(_DWORD *)(a1 + 16) = v3 + 1;\n      goto LABEL_11;\n    }\n    if ( !*a3 )\n    {\n      v4 = \"cannot switch from manual to automatic argument indexing\";\n      goto LABEL_10;\n    }\n  }\n  else\n  {\n    if ( v3 <= 0 )\n    {\n      *(_DWORD *)(a1 + 16) = -1;\n      --a2;\n      goto LABEL_11;\n    }\n    if ( !*a3 )\n    {\n      v4 = \"cannot switch from automatic to manual argument indexing\";\nLABEL_10:\n      *a3 = v4;\n    }\n  }\nLABEL_11:\n  if ( (unsigned __int64)a2 < *(_QWORD *)(a1 + 8) )\n    return (void *)(*(_QWORD *)a1 + 24LL * a2);\n  if ( !*a3 )\n    *a3 = \"argument index is out of range in format\";\n  return &unk_1800EAB38;\n}", "assembly": "; \n; fmt::internal::PrintfParser<wchar_t>::HandleArgIndex from 0x180042c80 to 0x180042cf2 (114 bytes)\n; \n; 1 xrefs:\n; > <???> @ 0x1801438a8\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\nmov     eax, [rcx+10h]                                                 ; +0x0, 0x180042c80\nmov     r9, rcx                                                        ; +0x3, 0x180042c83\ncmp     edx, 0FFFFFFFFh                                                ; +0x6, 0x180042c86\njz      short loc_180042CA9                                            ; +0x9, 0x180042c89\ntest    eax, eax                                                       ; +0xb, 0x180042c8b\njg      short loc_180042C9A                                            ; +0xd, 0x180042c8d\nmov     dword ptr [rcx+10h], 0FFFFFFFFh                                ; +0xf, 0x180042c8f\ndec     edx                                                            ; +0x16, 0x180042c96\njmp     short loc_180042CC6                                            ; +0x18, 0x180042c98\ncmp     qword ptr [r8], 0                                              ; +0x1a, 0x180042c9a\njnz     short loc_180042CC6                                            ; +0x1e, 0x180042c9e\nlea     rax, aCannotSwitchFr; \"cannot switch from automatic to manual \"... ; +0x20, 0x180042ca0\njmp     short loc_180042CC3                                            ; +0x27, 0x180042ca7\ntest    eax, eax                                                       ; +0x29, 0x180042ca9\njs      short loc_180042CB6                                            ; +0x2b, 0x180042cab\nmov     edx, eax                                                       ; +0x2d, 0x180042cad\ninc     eax                                                            ; +0x2f, 0x180042caf\nmov     [rcx+10h], eax                                                 ; +0x31, 0x180042cb1\njmp     short loc_180042CC6                                            ; +0x34, 0x180042cb4\ncmp     qword ptr [r8], 0                                              ; +0x36, 0x180042cb6\njnz     short loc_180042CC6                                            ; +0x3a, 0x180042cba\nlea     rax, aCannotSwitchFr_0; \"cannot switch from manual to automatic \"... ; +0x3c, 0x180042cbc\nmov     [r8], rax                                                      ; +0x43, 0x180042cc3\nmov     eax, edx                                                       ; +0x46, 0x180042cc6\ncmp     rax, [rcx+8]                                                   ; +0x48, 0x180042cc8\njnb     short loc_180042CDA                                            ; +0x4c, 0x180042ccc\nlea     rcx, [rax+rax*2]                                               ; +0x4e, 0x180042cce\nmov     rax, [r9]                                                      ; +0x52, 0x180042cd2\nlea     rax, [rax+rcx*8]                                               ; +0x55, 0x180042cd5\nretn                                                                   ; +0x59, 0x180042cd9\ncmp     qword ptr [r8], 0                                              ; +0x5a, 0x180042cda\njnz     short loc_180042CEA                                            ; +0x5e, 0x180042cde\nlea     rax, aArgumentIndexI; \"argument index is out of range in forma\"... ; +0x60, 0x180042ce0\nmov     [r8], rax                                                      ; +0x67, 0x180042ce7\nlea     rax, unk_1800EAB38                                             ; +0x6a, 0x180042cea\nretn                                                                   ; +0x71, 0x180042cf1", "xrefs": ["<???> @ 0x1801438a8"], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}