Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Side by Side Diff: pkg/dartino_compiler/lib/src/worker/developer.dart

Issue 2029723004: Don't quit debugger when the program terminates, only after `quit`. Base URL: git@github.com:dartino/sdk.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « pkg/dartino_compiler/lib/cli_debugger.dart ('k') | pkg/dartino_compiler/lib/vm_context.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dartino project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dartino project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE.md file. 3 // BSD-style license that can be found in the LICENSE.md file.
4 4
5 library dartino_compiler.worker.developer; 5 library dartino_compiler.worker.developer;
6 6
7 import 'dart:async' show 7 import 'dart:async' show
8 Future, 8 Future,
9 TimeoutException; 9 TimeoutException;
10 10
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after
711 // TODO(ahe): Need to continue to unwind stack. 711 // TODO(ahe): Need to continue to unwind stack.
712 break; 712 break;
713 case VmCommandCode.ProcessCompileTimeError: 713 case VmCommandCode.ProcessCompileTimeError:
714 state.log("Compile-time error"); 714 state.log("Compile-time error");
715 exitCode = exit_codes.DART_VM_EXITCODE_COMPILE_TIME_ERROR; 715 exitCode = exit_codes.DART_VM_EXITCODE_COMPILE_TIME_ERROR;
716 await printTrace(); 716 await printTrace();
717 // TODO(ahe): Continue to unwind stack? 717 // TODO(ahe): Continue to unwind stack?
718 break; 718 break;
719 719
720 case VmCommandCode.ProcessTerminated: 720 case VmCommandCode.ProcessTerminated:
721 await vmContext.terminate();
721 exitCode = 0; 722 exitCode = 0;
722 break; 723 break;
723 724
724 case VmCommandCode.ConnectionError: 725 case VmCommandCode.ConnectionError:
725 state.log("Error on connection to Dartino VM: ${command.error}"); 726 state.log("Error on connection to Dartino VM: ${command.error}");
726 exitCode = exit_codes.COMPILER_EXITCODE_CONNECTION_ERROR; 727 exitCode = exit_codes.COMPILER_EXITCODE_CONNECTION_ERROR;
727 break; 728 break;
728 729
729 default: 730 default:
730 throwInternalError("Unexpected result from Dartino VM: '$command'"); 731 throwInternalError("Unexpected result from Dartino VM: '$command'");
(...skipping 1410 matching lines...) Expand 10 before | Expand all | Expand 10 after
2141 addIfNotNull("open_ocd_board", open_ocd_board); 2142 addIfNotNull("open_ocd_board", open_ocd_board);
2142 return result; 2143 return result;
2143 } 2144 }
2144 } 2145 }
2145 2146
2146 Uri defaultSnapshotLocation(Uri script) { 2147 Uri defaultSnapshotLocation(Uri script) {
2147 // TODO(sgjesse): Use a temp directory for the snapshot. 2148 // TODO(sgjesse): Use a temp directory for the snapshot.
2148 String snapshotName = basenameWithoutExtension(script.path) + '.snapshot'; 2149 String snapshotName = basenameWithoutExtension(script.path) + '.snapshot';
2149 return script.resolve(snapshotName); 2150 return script.resolve(snapshotName);
2150 } 2151 }
OLDNEW
« no previous file with comments | « pkg/dartino_compiler/lib/cli_debugger.dart ('k') | pkg/dartino_compiler/lib/vm_context.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698