From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: GPS Debugger exit when "Ada.Text_IO.Put_Line" reached. Date: Fri, 01 Apr 2016 13:18:17 +0100 Organization: A noiseless patient Spider Message-ID: References: <75868a0e-c46d-4d7a-9c91-9d29edbe6622@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="7565da77bf95a8fe4c6cca3149d50047"; logging-data="19073"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+z9uIxPQO8bLyx87fwsKmj5TpjiXmW5nc=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (darwin) Cancel-Lock: sha1:sq8WrDlfY0FCeEKJsen6i2LY+lk= sha1:VVIkF7wwvNxEY0+8iX59ea1U/LM= Xref: news.eternal-september.org comp.lang.ada:29951 Date: 2016-04-01T13:18:17+01:00 List-Id: George J writes: > Hi all!I'm using GNAT GPS in my project. I have a problem with > debugging. When debugger reaches line > "Ada.Text_IO.Put_Line("Something");" it exit with "[Inferior 1 > (process X) exited with code 1]". So I can't understand, how I can > solve this problem. And BTW I have a question, is there any feature to > display only "Debug Messages" in console or not? George, why do you post messages three times? Please say what you mean by "when debugger reaches line". Did you put a breakpoint on it? If so, what did you do next? I most often use gdb from the command line rather than via GPS; there are four possibilities, (1) next => run until the next line in the current subprogram is reached, (2) step => if at a subprogram call, run until the first line of the subprogram, otherwise as next I think, (3) finish => run until the current subprogram returns, (4) continue => run until another breakpoint/exception/end of program (your program ran to end of program). In GPS, the buttons that control this are displayed (only while debugging) at the right-hand end of the row of buttons under the menu bar. You do have to have compiled your code for debug (for example, you can't step into a subprogram that wasn't compiled for debug).