Skip to content

Commit

Permalink
Log only if breakpoint not verified.
Browse files Browse the repository at this point in the history
  • Loading branch information
maziac committed Apr 11, 2020
1 parent 266f9d5 commit eb40fe0
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
6 changes: 3 additions & 3 deletions design/AddingNewRemotes.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ Since you also need a transport layer to communicate with Remote it is normally

Here are some exemplary methods that need to be overwritten:
- Lifecycle
- init: Initialization of the Remote. Called by ... when ... TODO
- disconnect: Disconnects the Remote. E.g. diconnect the Transport. Called by ... when ... TODO
- terminate: Terminates the Remote. TODO: difference to disconnect?
- init: Initialization of the Remote. Called by DebugSessionclass when launchRequest is received from vscode (also by Z80UnitTests).
- disconnect: Disconnects the Remote. E.g. disconnect the Transport. Called by DebugSessionclass when disconnectRequest is received from vscode (also by Z80UnitTests).
- terminate: Terminates the Remote. Z80UnitTests uses this to terminate a possibly running Remote instance before starting. Only difference to disconnect is that 'terminated' would be emitted. TODO: Remove?
- Data
- getRegisters: Ask the Transport to get the register values from the external Remote.
- setRegisterValue: Communicates with the Transport to set a specific Register value.
Expand Down
8 changes: 5 additions & 3 deletions src/debugadapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -597,9 +597,11 @@ export class DebugSessionClass extends DebugSession {
const lineNr=this.convertDebuggerLineToClient(cbp.lineNr);
const verified=(cbp.address>=0); // Is not verified if no address is set
let bp=new Breakpoint(verified, lineNr, 0, source);
// TODO: REMOVE
const text=JSON.stringify(bp);
vscode.debug.activeDebugConsole.appendLine(text);
// TODO: REMOVE:
if (!verified) {
const text=JSON.stringify(bp);
vscode.debug.activeDebugConsole.appendLine(text);
}
return bp;
});

Expand Down
2 changes: 1 addition & 1 deletion src/z80unittests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ export class Z80UnitTests {
// Wait until vscode debugger has stopped.
if (Remote) {
// Terminate emulator
await Remote.terminate();
await Remote.terminate(); // TODO: Z80UnitTests is the only one who uses this function. Maybe I can change this to 'disconnect'.
}
// (Unfortunately there is no event for this, so we need to wait)
Utility.delayedCall(time => {
Expand Down

0 comments on commit eb40fe0

Please sign in to comment.