From: Jerome Guitton <guitton@act-europe.fr>
To: gdb-patches@sources.redhat.com, Elena Zannoni <ezannoni@redhat.com>
Subject: Re: [RFA/testsuite] Ada fixed points [was stabs: octal negative numbers]
Date: Mon, 29 Nov 2004 10:24:00 -0000 [thread overview]
Message-ID: <20041129102424.GJ20670@adacore.com> (raw)
In-Reply-To: <20041128174901.GD24639@nevyn.them.org>
[-- Attachment #1: Type: text/plain, Size: 303 bytes --]
Daniel Jacobowitz (drow@false.org):
> Please don't hardcode "run". Can you use
> "runto ${srcfile}:$bp_location"
> instead of these two lines?
> Please add a copyright notice to this file.
Daniel,
Thank you for your review. I fixed these two problems; new files in
attachment. OK now?
--
Jerome
[-- Attachment #2: fixed_points.exp --]
[-- Type: text/plain, Size: 1480 bytes --]
# Copyright 2004 Free Software Foundation, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
# USA.
if $tracelevel then {
strace $tracelevel
}
load_lib "ada.exp"
set testfile "fixed_points"
set srcfile ${testfile}.adb
set binfile ${objdir}/${subdir}/${testfile}
if {[gdb_compile_ada "${srcfile}" "${binfile}" executable [list debug ]] != "" } {
return -1
}
gdb_exit
gdb_start
gdb_reinitialize_dir $srcdir/$subdir
gdb_load ${binfile}
set bp_location [gdb_get_line_number "Set breakpoint here"]
runto "${srcfile}:$bp_location"
gdb_test "print base_object" \
".* = -50" \
"p on a fixed point type"
gdb_test "print subtype_object" \
".* = -50" \
"p on a subtype fixed point type"
gdb_test "print new_type_object" \
".* = -50" \
"p on a new fixed point type"
[-- Attachment #3: fixed_points.adb --]
[-- Type: text/plain, Size: 1467 bytes --]
-- Copyright 2004 Free Software Foundation, Inc.
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 2 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program; if not, write to the Free Software
-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
with System;
procedure Fixed_Points is
type Base_Fixed_Point_Type is
delta 1.0 / 16.0
range (System.Min_Int / 2) * 1.0 / 16.0 ..
(System.Max_Int / 2) * 1.0 / 16.0;
subtype Fixed_Point_Subtype is
Base_Fixed_Point_Type range -50.0 .. 50.0;
type New_Fixed_Point_Type is
new Base_Fixed_Point_Type range -50.0 .. 50.0;
Base_Object : Base_Fixed_Point_Type := -50.0;
Subtype_Object : Fixed_Point_Subtype := -50.0;
New_Type_Object : New_Fixed_Point_Type := -50.0;
begin
Base_Object := 1.0/16.0; -- Set breakpoint here
Subtype_Object := 1.0/16.0;
New_Type_Object := 1.0/16.0;
end Fixed_Points;
next prev parent reply other threads:[~2004-11-29 10:24 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-26 17:39 [RFA] stabs: octal negative numbers Jerome Guitton
2004-10-26 17:50 ` Joel Brobecker
2004-11-23 14:10 ` Jerome Guitton
2004-11-23 14:32 ` Elena Zannoni
2004-11-23 14:38 ` Jerome Guitton
2004-11-25 19:20 ` [RFA/testsuite] Ada fixed points [was stabs: octal negative numbers] Jerome Guitton
2004-11-28 17:49 ` Daniel Jacobowitz
2004-11-29 10:24 ` Jerome Guitton [this message]
2004-11-29 13:42 ` Daniel Jacobowitz
2004-11-29 15:21 ` Andrew Cagney
2004-11-29 15:26 ` Daniel Jacobowitz
2004-11-29 17:24 ` Jerome Guitton
2004-12-01 17:17 ` Jerome Guitton
2004-12-13 17:21 ` Jerome Guitton
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20041129102424.GJ20670@adacore.com \
--to=guitton@act-europe.fr \
--cc=ezannoni@redhat.com \
--cc=gdb-patches@sources.redhat.com \
/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