Hi,
Here is my LZZ code:
#src
#include <iostream>
#end
using namespace std;
int main()
{
cout << "Hello world 1" << endl;
cout << "Hello world 2" << endl;
cout << "Hello world 3" << endl;
cout << "Hello world 4" << endl;
}
The two generated files:
// Test.h
//
#ifndef LZZ_Test_h
#define LZZ_Test_h
#define LZZ_INLINE inline
#line 7 "Test.lzz"
int main ();
#undef LZZ_INLINE
#endif
// Test.cpp
//
#include "Test.h"
#line 2 "Test.lzz"
#include <iostream>
#define LZZ_INLINE inline
#line 5 "Test.lzz"
using namespace std;
#line 7 "Test.lzz"
int main ()
#line 8 "Test.lzz"
{
cout << "Hello world 1" << endl;
cout << "Hello world 2" << endl;
cout << "Hello world 3" << endl;
cout << "Hello world 4" << endl;
}
#undef LZZ_INLINE
I put a breakpoint on the first cout and single step the rest of the program, here is the debug log. Everything appears in the terminal as it should, the only thing missing is the triangle. Pls forgive if I've missed something obvious, I am new to the IDE.
Steve
LD_LIBRARY_PATH=.:
Command-line: /usr/bin/gdb -nx -fullname -quiet -args bin/Debug/TestLzz
Working dir : /home/steve/TestLzz/
Reading symbols from /home/steve/TestLzz/bin/Debug/TestLzz...done.
(gdb)
> set prompt >>>>>>cb_gdb:
Executing: xterm -T 'Program Console' -e sleep 107722
>>>>>>cb_gdb:
> show version
GNU gdb (Ubuntu/Linaro 7.3-0ubuntu2) 7.3-2011.08
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.launchpad.net/gdb-linaro/>.
>>>>>>cb_gdb:
> set confirm off
>>>>>>cb_gdb:
> set width 0
>>>>>>cb_gdb:
> set height 0
>>>>>>cb_gdb:
> set breakpoint pending on
>>>>>>cb_gdb:
> set print asm-demangle on
>>>>>>cb_gdb:
> set unwindonsignal on
>>>>>>cb_gdb:
> set disassembly-flavor intel
>>>>>>cb_gdb:
> catch throw
Function "__cxa_throw" not defined.
Catchpoint 1 (throw)
>>>>>>cb_gdb:
> source /usr/share/codeblocks/scripts/stl-views-1.0.3.gdb
Executing: ps x -o tty,pid,command
>>>>>>cb_gdb:
> directory /home/steve/TestLzz/
>>>>>>cb_gdb:
> break "/home/steve/TestLzz/Test.lzz:9"
PS result: ? 28333 ps x -o tty,pid,command
PS result: pts/0 28330 sleep 107722
TTY is[/dev/pts/0]
GetConsoleTTY[/dev/pts/0]ConsolePid[28328]
Queued:[tty /dev/pts/0]
Breakpoint 2 at 0x400758: file Test.lzz, line 9.
>>>>>>cb_gdb:
> tty /dev/pts/0
>>>>>>cb_gdb:
> run
Breakpoint 2, main () at Test.lzz:9
/home/steve/TestLzz/Test.lzz:9:66:beg:0x400758
>>>>>>cb_gdb:
> next
/home/steve/TestLzz/Test.lzz:10:102:beg:0x40076f
>>>>>>cb_gdb:
> next
/home/steve/TestLzz/Test.lzz:11:138:beg:0x400786
>>>>>>cb_gdb:
> next
/home/steve/TestLzz/Test.lzz:12:174:beg:0x40079d
>>>>>>cb_gdb:
> next
/home/steve/TestLzz/Test.lzz:13:210:beg:0x4007b4
>>>>>>cb_gdb:
> next
258 libc-start.c: No such file or directory.
__libc_start_main (main=0x400754 <main()>, argc=1, ubp_av=0x7fffffffe6f8, init=<optimised out>, fini=<optimised out>, rtld_fini=<optimised out>, stack_end=0x7fffffffe6e8) at libc-start.c:258
in libc-start.c
>>>>>>cb_gdb:
> next
[Inferior 1 (process 28334) exited normally]
>>>>>>cb_gdb:
> next
The program is not being run.
>>>>>>cb_gdb:
> quit