unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: avinashu@gmail.com
To: help-gnu-emacs@gnu.org
Subject: gdb emacs help newbie
Date: 26 Feb 2007 08:45:36 -0800	[thread overview]
Message-ID: <1172508336.353799.129060@j27g2000cwj.googlegroups.com> (raw)

Hello Everyone
 I am a newbie with Linux/GDB/emacs. I am connecting to a linux server
using ssh client and using it to run c++ programs. I am trying to use
the gdb debugger with emacs. This is a simple program i am trying to
use the debugger on.
# include <iostream.h>
# include <math.h>
void modify_array(int [],int);

int main()
{
    int a[5]={0,1,2,3,4};
    int i;
    cout<<endl;
    for(i=0;i<5;i++) cout<<a[i]<<"       ";
    modify_array(a,5);
    cout<<endl;
    for(i=0;i<5;i++) cout<<a[i]<<"       ";

}
void modify_array(int ref[], int arraysize)
{
    int i;
    for(i=0;i<arraysize;i++) ref[i]=ref[i]*3;


}

these are the commands I type out
emacs
[ESC] x gdb [ENTER]
gdb a.out
break 6
run
Now the screen has split into 2 and and u see the code of the cpp file
in the top window and gdb command line in the botton

window
I type n and then n to go to the next lines
The cursor is on line 8 now
When I try to set a breakpoint using:
C-c C-b I get the following message "wrong type argument, sequencep,8"
I get the same message with C-x [SPC]

I get the same message for other lines and other files i tried

Any help would be appreciated!!!!

             reply	other threads:[~2007-02-26 16:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-26 16:45 avinashu [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-02-27 21:22 gdb emacs help newbie Nick Roberts

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1172508336.353799.129060@j27g2000cwj.googlegroups.com \
    --to=avinashu@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).