logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Devel::GDB::LowLevel - Low-level interface for communicating with GDB

Authors

       Antal Novak <afn@cpan.org>, Josef Ezra <jezra@cpan.org>

Constructor

       new Spawns  a  GDB  process.   Because  this  class only facilitates communication with GDB (not with the
           inferior process being debugged), you have to decide what to  do  with  the  "STDIN",  "STDOUT",  and
           "STDERR" of that process.  There are a few options available:

           •   If STDIN is a tty, we can have the inferior process communicate directly with the controlling tty
               (emulating the default behavior of gdb):

                   $gdb = new Devel::GDB::LowLevel( '-execfile' => $path_to_gdb,
                                                    '-params'   => $extra_gdb_params );

           •   Or, we can create an "Expect" object to communicate with the inferior process:

                   $gdb = new Devel::GDB::LowLevel( '-create-expect' => 1 );
                   $expect = $gdb->get_expect_obj();

           •   Or, we can create our own tty and use that:

                   $gdb = new Devel::GDB::LowLevel( '-use-tty' => '/dev/pts/123' );

Description

       This module is used internally by Devel::GDB.  It handles the low-level I/O of communicating with the GDB
       process.

Methods

       send
           Sends a raw line of text to GDB.  This should not contain any newlines (they will be stripped).  This
           method only sends a request, and does not wait for a response.

       get_reader
           Returns the file handle from which to read GDB responses.

       get_expect_obj
           Returns  the  "Expect" object created in the constructor.  Dies if '-create-expect' was not passed to
           "new".

       interrupt
           Send SIGINT to the GDB session, interrupting the inferior process (if any).

Name

       Devel::GDB::LowLevel - Low-level interface for communicating with GDB

See Also

       IPC::Open2

See Also