OLD | NEW |
1 /* Reverse execution and reverse debugging. | 1 /* Reverse execution and reverse debugging. |
2 | 2 |
3 Copyright (C) 2006-2012 Free Software Foundation, Inc. | 3 Copyright (C) 2006-2013 Free Software Foundation, Inc. |
4 | 4 |
5 This file is part of GDB. | 5 This file is part of GDB. |
6 | 6 |
7 This program is free software; you can redistribute it and/or modify | 7 This program is free software; you can redistribute it and/or modify |
8 it under the terms of the GNU General Public License as published by | 8 it under the terms of the GNU General Public License as published by |
9 the Free Software Foundation; either version 3 of the License, or | 9 the Free Software Foundation; either version 3 of the License, or |
10 (at your option) any later version. | 10 (at your option) any later version. |
11 | 11 |
12 This program is distributed in the hope that it will be useful, | 12 This program is distributed in the hope that it will be useful, |
13 but WITHOUT ANY WARRANTY; without even the implied warranty of | 13 but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
15 GNU General Public License for more details. | 15 GNU General Public License for more details. |
16 | 16 |
17 You should have received a copy of the GNU General Public License | 17 You should have received a copy of the GNU General Public License |
18 along with this program. If not, see <http://www.gnu.org/licenses/>. */ | 18 along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
19 | 19 |
20 #include "defs.h" | 20 #include "defs.h" |
21 #include "gdb_string.h" | 21 #include <string.h> |
22 #include "target.h" | 22 #include "target.h" |
23 #include "top.h" | 23 #include "top.h" |
24 #include "cli/cli-cmds.h" | 24 #include "cli/cli-cmds.h" |
25 #include "cli/cli-decode.h" | 25 #include "cli/cli-decode.h" |
26 #include "cli/cli-utils.h" | 26 #include "cli/cli-utils.h" |
27 #include "inferior.h" | 27 #include "inferior.h" |
28 #include "regcache.h" | 28 #include "regcache.h" |
29 | 29 |
30 /* User interface: | 30 /* User interface: |
31 reverse-step, reverse-next etc. */ | 31 reverse-step, reverse-next etc. */ |
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
252 unsigned long num; | 252 unsigned long num; |
253 | 253 |
254 if (args == NULL || args[0] == '\0') | 254 if (args == NULL || args[0] == '\0') |
255 error (_("Command requires an argument.")); | 255 error (_("Command requires an argument.")); |
256 | 256 |
257 if (strncmp (args, "start", strlen ("start")) == 0 | 257 if (strncmp (args, "start", strlen ("start")) == 0 |
258 || strncmp (args, "begin", strlen ("begin")) == 0 | 258 || strncmp (args, "begin", strlen ("begin")) == 0 |
259 || strncmp (args, "end", strlen ("end")) == 0) | 259 || strncmp (args, "end", strlen ("end")) == 0) |
260 { | 260 { |
261 /* Special case. Give target opportunity to handle. */ | 261 /* Special case. Give target opportunity to handle. */ |
262 target_goto_bookmark (args, from_tty); | 262 target_goto_bookmark ((gdb_byte *) args, from_tty); |
263 return; | 263 return; |
264 } | 264 } |
265 | 265 |
266 if (args[0] == '\'' || args[0] == '\"') | 266 if (args[0] == '\'' || args[0] == '\"') |
267 { | 267 { |
268 /* Special case -- quoted string. Pass on to target. */ | 268 /* Special case -- quoted string. Pass on to target. */ |
269 if (args[strlen (args) - 1] != args[0]) | 269 if (args[strlen (args) - 1] != args[0]) |
270 error (_("Unbalanced quotes: %s"), args); | 270 error (_("Unbalanced quotes: %s"), args); |
271 target_goto_bookmark (args, from_tty); | 271 target_goto_bookmark ((gdb_byte *) args, from_tty); |
272 return; | 272 return; |
273 } | 273 } |
274 | 274 |
275 /* General case. Bookmark identified by bookmark number. */ | 275 /* General case. Bookmark identified by bookmark number. */ |
276 num = get_number (&args); | 276 num = get_number (&args); |
277 ALL_BOOKMARKS (b) | 277 ALL_BOOKMARKS (b) |
278 if (b->number == num) | 278 if (b->number == num) |
279 break; | 279 break; |
280 | 280 |
281 if (b) | 281 if (b) |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
394 Argument is a bookmark number or numbers,\n\ | 394 Argument is a bookmark number or numbers,\n\ |
395 or no argument to delete all bookmarks.\n"), | 395 or no argument to delete all bookmarks.\n"), |
396 &deletelist); | 396 &deletelist); |
397 add_com ("goto-bookmark", class_bookmark, goto_bookmark_command, _("\ | 397 add_com ("goto-bookmark", class_bookmark, goto_bookmark_command, _("\ |
398 Go to an earlier-bookmarked point in the program's execution history.\n\ | 398 Go to an earlier-bookmarked point in the program's execution history.\n\ |
399 Argument is the bookmark number of a bookmark saved earlier by using \n\ | 399 Argument is the bookmark number of a bookmark saved earlier by using \n\ |
400 the 'bookmark' command, or the special arguments:\n\ | 400 the 'bookmark' command, or the special arguments:\n\ |
401 start (beginning of recording)\n\ | 401 start (beginning of recording)\n\ |
402 end (end of recording)\n")); | 402 end (end of recording)\n")); |
403 } | 403 } |
OLD | NEW |