Command: DS Usage: DS ASC range Auto-define T_#### where # is the address
| 608 | // DS <addr> |
| 609 | // ASC range Auto-define T_#### where # is the address |
| 610 | Update_t CmdDisasmDataDefString ( int nArgs ) |
| 611 | { |
| 612 | int iCmd = 0; // Define Ascii, AppleText, MixedText (DOS3.3) |
| 613 | |
| 614 | if (nArgs > 4) // 2.7.0.31 Bug fix: DB range, i.e. DB 174E:174F |
| 615 | { |
| 616 | return Help_Arg_1( CMD_DEFINE_DATA_STR + iCmd ); |
| 617 | } |
| 618 | |
| 619 | DisasmData_t tData; |
| 620 | int iArg = 2; |
| 621 | |
| 622 | if (nArgs == 3 ) // 2.7.0.32 Bug fix: ASC range, i.e. ASC 174E:175F |
| 623 | { |
| 624 | if ( g_aArgs[ 2 ].eToken == TOKEN_COLON ) |
| 625 | iArg = 1; |
| 626 | } |
| 627 | |
| 628 | WORD nAddress = _CmdDefineByteRange( nArgs, iArg, tData ); |
| 629 | |
| 630 | // tData.iDirective = g_aAssemblerFirstDirective[ g_iAssemblerSyntax ] + ASM_DEFINE_APPLE_TEXT; |
| 631 | tData.iDirective = FIRST_M_DIRECTIVE + ASM_M_ASCII; // ASM_MERLIN |
| 632 | |
| 633 | tData.eElementType = (Nopcode_e)( NOP_STRING_APPLE + iCmd ); |
| 634 | tData.bSymbolLookup = false; |
| 635 | tData.nTargetAddress = 0; |
| 636 | |
| 637 | // Already exists, so update |
| 638 | DisasmData_t *pData = Disassembly_IsDataAddress( nAddress ); |
| 639 | if ( pData ) |
| 640 | { |
| 641 | *pData = tData; |
| 642 | } |
| 643 | else |
| 644 | Disassembly_AddData( tData ); |
| 645 | |
| 646 | return UPDATE_DISASM | ConsoleUpdate(); |
| 647 | } |
| 648 | |
| 649 | // __ Disassembler View Interface ____________________________________________________________________ |
| 650 |
nothing calls this directly
no test coverage detected