HDTenEightyP/NetNews huggingface dataset:
From: mahesh@evb.com (B.G. Mahesh)
Subject: Help with setting up environment for RISCada wanted.
Reply-To: mahesh@evb.com
Organization: SETT Inc.
Affiliate-Of: EVB Software Engineering, Inc.
Distribution: usa
Date: Sun, 16 Aug 1992 16:03:39 GMT


I am trying to setup the environment variables to use the TeleSoft
Ada compiler. My .cshrc has the following settings.


setenv  XAPPLRESDIR      ~/app-defaults

#----
# TeleSoft Ada
#----
setenv telesoft /usr/local/TeleSoft
setenv TELESOFT $telesoft
set path = ($path $telesoft/v4.1/host/bin)
setenv XUSER TRUE
setenv EDITOR vi
setenv DISPLAY widget:0.0
setenv TELEGEN2 $telesoft/v4.1
setenv ARCS_TUTORIAL $telesoft/host/examples/arcs/tutorial
source $telesoft/setall

When I login I get the message,

To use a particular RISCAda/SPARC product, enter the command:
	     setup [ <version> <target> ]
/usr/local/TeleSoft
/usr/home/mahesh

Set up complete for RISCAda product
    Version      :  v4.1
    Target       :  host
    In directory :  /usr/local/TeleSoft/v4.1/host

After this it hangs, when I type  control-C, i get the following messages

^C^C`/usr/ucb/which xset`: Ambiguous.
`/usr/ucb/which xset`: Ambiguous.
`/usr/ucb/which xset`: Ambiguous.

Any idea where things may be going wrong ? Please respond by email.

thanks

-- 

B.G. Mahesh
mahesh@evb.com
Newsgroups: comp.lang.ada
From: costello@mbunix.mitre.org (Costello)
Subject: ADT functions working with multiple derived types
Organization: The MITRE Corp., Bedford, Ma.
Distribution: usa
Date: Fri, 14 Aug 1992 18:40:08 GMT

Hi Folks,
    I have created an Abstract Data Type (ADT). That is, I have a package
that declares a type and functions which work on that type.  Now, I can
derive from that ADT type and then all of those functions are available
to me with the new type.  This works fine.
   
    The problem arises when, in the ADT package, I declare two types and 
have functions which work on both types.  When I then do my deriving I 
derive on both types.  Now, when I invoke the function which is supposed
to work on both types I get a compiler error:

>>>>SEMANTIC : Unresolvable expression <8.3, 8.7>

I have concluded that ADTs can only work on one type. Is this correct?

Here is an example.  Suppose we have the ADT called junk:
 
package junk is
   subtype one is integer range 1..10;
   type two is record
      x : integer range 1..20;
   end record;
   function p (a : one) return two;
end junk;

package body junk is
   function p (a : one) return two is
   r : two;
   begin
      r.x := a;
      return r;
   end p;
end junk;

Here is a procedure to test the ADT:

with junk; use junk;

procedure p_test is
type new1 is new one;
type new2 is new two;
g: new1;
h : two;
begin
    g := 5;
    h := p(g);
end p_test;

When I compile this procedure I get the above error message.
Note that when I change the second assignment statement to:
  
   h := two(p(g));

then I don't get the compiler error.  If you could shed some 
light on this I would appreciate it.  Please send replies to:

   costello@mitre.org

Thanks.  /Roger
Newsgroups: comp.lang.ada
From: falis@ajpo.sei.cmu.edu (Edward Falis)
Subject: Re: Are strings automatically free'd?
Summary: It depends on the implementation
Keywords: Automatic storage reclamation
Organization: Alsys
Date: Wed, 12 Aug 1992 13:49:13 GMT

The short answer is that this will be implementation dependent, so ask 
your vendor.

In most cases, there either won't be automatic reclamation, or the reclamation
will be tied to the scope where the access type is defined (not where the
allocator is executed).  In that scenario, all allocated objects would be
reclaimed at exit of the scope defining the access type (one way of 
implementing pragma CONTROLLED).

This seems not ot be the case in your example code, so you ought to use
unchecked deallocation, which is more likely to work across the various
implementations you're looking at.  The final caveat is to (once again)
taslk to your vendor, since there are implementations where unchecked
deallocation is either deferred, or simply not done.

For the Alsys implementations, the allocated objects are reclaimed when
the scope defining the access type is exited, and unchecked deallocation
reclaims immediately.

- Ed Falis, Alsys
From: pelakh@convex.com (Boris Pelakh)
Newsgroups: comp.lang.ada
Subject: Re: Ada tasking overhead
Keywords: tasking
Date: 19 Aug 92 15:56:45 GMT
Organization: Engineering, CONVEX Computer Corp., Richardson, Tx., USA
X-Disclaimer: This message was written by a user at CONVEX Computer
              Corp. The opinions expressed are those of the user and
              not necessarily those of CONVEX.

In article <1992Aug18.233552.27012@nosc.mil> fortin@nosc.mil (Richard G. Fortin) writes:
>Hello,
>
>We were wondering if anyone has done a tasking overhead study with the latest
>version of the Verdix Ada compiler (even more interested if it was VADSworks)?
>We're not real concerned with rendevouz, more with task start-up and teardown.
>

This is a configuration/architecture dependent measure. You can get the PIWG
suite from ajpo and run the C tests and the T tests (look at the READ.ME) to
get specific measures. These tests are rather comprehensive.

-- 
Boris Pelakh		Ada Project Leader          pelakh@convex.com
		     Convex Computer Corporation
"If winning isn't important, why keep score ?"	-- Lt. Worf, Star Trek TNG.
From: crispen@efftoo.boeing.com (crispen)
Newsgroups: comp.lang.ada
Subject: Re: Multiple Inheritance -- the last post?
Date: 21 Aug 92 15:03:15 GMT
Distribution: world
Organization: The Internet

seas.gwu.edu!mfeldman@uunet.uu.net (Mike Feldman) says:

>It's time for a little bridge building in the otrher direction - high time, 
>in my opinion. I am getting rather bored with hearing the word "academic" 
>thrown around with the derision that conservatives reserve for the word 
>"liberal."

I will certainly withdraw the word, since my belligerence was intended
to raise the visibility of the issue, not to have people take issue
with the manner in which it was stated.  Looking back, it was probably
a bad idea, though I note that the first, less outrageous posting of
this question raised only a single email note to me while the second
has filled my mailbox nicely (I promise to summarize).

So, everyone please disregard the original note and email to me if you
think that there is a domain in which MI is both a natural part of a
domain-specific software architecture and a safe and effective technique
(e.g., system integration or component debug took *less* time than
previously).

And apologies to all for the waste of bandwidth.

Bob Crispen
crispen@foxy.boeing.com
Newsgroups: comp.lang.ada
From: sinan@milton.u.washington.edu (Sinan Karasu)
Subject: Sun/Verdix circular elaboration revisited
Keywords: Ada 
Organization: University of Washington, Seattle
Date: Fri, 14 Aug 1992 14:35:47 GMT

 About 2 weeks ago I complained ( to put it lightly ) about Sun/Verdix Ada
and a circular elaboration problem. Well , next morning I had 6 e-mails
and a phone call , some from Verdix some from Sun . These people must have 
worked the weekend to work on my problem and get me a tape by next wednesday.
I was very pleasantly surprised( to say the least) and would like to publicly
apologize to be so unpleasant to this great bunch of people.I have always
had the highest regard for Sun anyway (I do have 2 SparcStations at home
after all) . But Verdix joins the ranks of the companies that I will 
hold in the highest regard from now on...
Thanx .......
Sinan

Newsgroups: comp.lang.ada
From: obry@flash.bellcore.com (Pascal Obry)
Subject: Re: TEXT_IO.FILE_TYPE passing
Organization: /u/obry/.organization
Date: 18 Aug 92 13:46:23


david,

This is because FILE_TYPE is a limited private type and for these kind of type
there is no assigment operator provided.

So you should do something like this :

   procedure OPEN_OR_CREATE_FILE (THE_FILE : in out FILE_TYPE;
				  THE_MODE : FILE_MODE := IN_FILE)
      FILE_NAME : STRING (80);
      INDEX     : NATURAL := 0;
      begin
         PUT ("Input file name:  ");
         GET_LINE (ITEM => FILE_NAME,
                   LAST => INDEX);
         if THE_MODE = IN_FILE then
            OPEN (FILE => THE_FILE,
                  MODE => IN_FILE,
                  NAME => FILE_NAME (1 .. INDEX));
         else
            CREATE (FILE => THE_FILE,
                    MODE => OUT_FILE,
                    NAME => FILE_NAME (1 .. INDEX));
         end if;
      end OPEN_OR_CREATE_FILE;

And now you can use it by :

      OPEN_OR_CREATE_FILE (THE_FILE => INPUT_FILE, THE_MODE => IN_FILE);

About this read [LRM 7.4.4] ...

I hope this help,
Pascal.
--

-------------------------------------------------------------------------------
--  Pascal OBRY								     --
--  Room 2D-337				e_mail : obry@bellcore.com  	     --
--  Bellcore								     --
--  445 South Street			voice : 1 - 201 829 4039	     --
--  Post Office Box 1910						     --
--  Morristown, New Jersey 07962-1910					     --
-------------------------------------------------------------------------------

  `` inheritance is surely a good answer, but who knows the question ? ''

Newsgroups: comp.lang.ada
From: fjh@munta.cs.mu.OZ.AU (Fergus James HENDERSON)
Subject: Re: Type Extensions VS Classes (was Re: Object Oriented Ada...)
Organization: Computer Science, University of Melbourne, Australia
Date: Wed, 12 Aug 1992 16:53:02 GMT

alex@cs.umd.edu (Alex Blakemore) writes:

>In article <9222000.23050@mulga.cs.mu.OZ.AU> fjh@munta.cs.mu.OZ.AU (Fergus James HENDERSON) writes:
>> Does Ada-9X have any concept similar to C++'s abstract base classes?
>
>Yes.
>
>An abstract type is one that has one or more abstract operations.
>An abstract operation (subprogram) has no body. They are used to define
>the profile of an operation that (non abstract) types derived
>from the abstract parent must provide.
>
>It is a compile time error to declare an object of an
>abstract type.  That is an improvement over C++.

It *is* an error to declare an object of an abstract type in C++.
For example:
    $ cat > abstract.c
    class Shape {
    public:
        virtual void draw() = 0;
    };
    int main(void) {
        Shape s;
        return 0;
    }
    $ CC abstract.c
    "abstract.c", line 6: error:  declaration of object of abstract class Shape

>If you want the C++ ability to declare objects of the
>abstract type (which means that the type is not really abstract),
>just supply a null body for the relevant operations.

C++ does not have this ability.

-- 
Fergus Henderson             fjh@munta.cs.mu.OZ.AU      
This .signature VIRUS is a self-referential statement that is true - but 
you will only be able to consistently believe it if you copy it to your own
.signature file!
From: sahni@eik.ii.uib.no (Sahni Daljeet Singh)
Newsgroups: comp.lang.ada
Subject: ADA question
Keywords: Strings, Packages
Date: 23 Aug 92 10:20:56 GMT
Organization: Institute of Informatics, University of Bergen, Norway

I am beginning to learn Ada and am stuck at a point. The question is as
follows:

I have a function in a package A which returns string. I am using
that function in another package B and try to give the value returned
by that function to a variable (which has been declared in package B).
The variable is of type string (1 .. max) initialised to empty string.
My program simple raises an exception. 
Could it be that the array size is different for the variable and the value
returned by the function. The function can return a string of different
sizes. Can somebody give help me out?

Thanks.
Daljeet.
Newsgroups: comp.lang.ada
From: rmo@sei.cmu.edu (Robert Ollerton)
Subject: Re: Dynamic Task Creation/Control
Organization: Software Engineering Institute
Date: Sat, 22 Aug 1992 14:00:34 GMT

     I encountered the problem of dynamic task creation/destruction in
the development of the Ada Process-Oriented Simulation Library (APOSL).
The essence of the APOSL solution is to encapsulate the task logic within
a loop that stops and starts task execution.  
     All tasks in this system are created through the evaluation of 
allocators declared in the outer scope of library-level packages.  The 
following semi-code is a simplification of the this approach.

     Hope this helps.

------

package Task_Pkg is

  type Task_Ptr is
    private;

  procedure Create
    ( The_Task : out Task_Ptr );

  procedure Destroy
    ( The_Task : in out Task_Ptr );

  procedure Entry_1
    ( The_Task : in Task_Ptr );

  procedure Entry_2;
    ( The_Task : in Task_Ptr );

  pragma Inline (Entry_1, Entry_2);
      
private

  task body Reusable_Task is
    entry Start_Executing;
    entry Stop_Executing;
    entry Entry_1;
    entry Entry_2;
  end Reusable_Task;

  type Task_Ptr is
    access Reusable_Task;

end Task_Pkg;

package body Task_Pkg is

  Storage
    : Stack_Of_Task_Ptr;

  procedure Create
      ( The_Task : out Task_Ptr ) is
    New_Task
      : Task_Ptr;
  begin
    if Empty(Storage) then
      New_Task := new Example;
    else
      Pop(Storage,New_Task);
    end if;
    New_Task.Start_Executing;
    The_Task := New_Task;
  end Create;

  procedure Destroy
    ( The_Task : in out Task_Ptr ) is
  begin
    The_Task.Stop_Executing;
    Push(Storage,The_Task);
    The_Task := null;
  end Destroy;

  procedure Entry_1
    ( The_Task : in Task_Ptr ) is
  begin
    The_Task.Entry_1;
  end Entry_1;

  procedure Entry_2
    ( The_Task : in Task_Ptr ) is
  begin
    The_Task.Entry_2;
  end Entry_2;

  task body Reusable_Task is
  begin
    loop
      entry Start_Executing;
      loop
        select 
          accept Stop_Executing;
          exit;
        or
          accept Entry_1;
           -- Task Entry Logic
        or
          accept Entry_2;
           -- Task Entry Logic
        end select;
      end loop;
    end loop;
  end Reusable_Task;

end Task_Pkg;

-----

These opinions are my own and nobody else's.

Robert Ollerton
Navy Resident to SEI
Naval Command, Control and Ocean Surveilance Center Research, Development
Test and Evaluation Division

ollerton@nosc.mil
rmo@sei.cmu.edu
From: alex@cs.umd.edu (Alex Blakemore)
Newsgroups: comp.lang.ada
Subject: Re: Ada 9x Dispatching Question
Keywords: Ada Dispatching Polymorphism
Date: 13 Aug 92 19:24:35 GMT
Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742

In article <334@sps.com> jot@sps.com (Joe Tallet) writes:
> I have a question concerning the code within Alex's article.
> >procedure client (x : shapes.shape) is
> >  shapes.draw (x); -- dispatches

I posted a followup previously - there was an error in my example
the procedure should read
  procedure client (x : shapes.shape'class) is
                                    ^^^^^^^
> My understanding of the dispatching is that the USE clause is necessary.
I dont think so - the draw operation dispatches 
primarily because shapes.shape is tagged.


-- 
---------------------------------------------------
Alex Blakemore alex@cs.umd.edu   NeXT mail accepted
From: SAHARBAUGH@ROO.FIT.EDU
Newsgroups: comp.lang.ada
Subject: Guaranteed task timing
Date: 15 Aug 92 13:00:00 GMT
Organization: The Internet


Richard Pettit asks:

>Is there a way to guarantee that a task will only 
>run a specified amount
>of time granular to 100 milliseconds or less?  The 
>solution must use
>only Ada language features.  Please respond to the 
>newsgroup.  Thanks.
>
>Rich
>
>------------------------------


We plan a first public showing at Tri-Ada 92 of K1, 
an alternate task scheduling system for Ada tasks. 
K1 provides hard deadline scheduling (periodic and 
aperiodic), performance monitoring, overrun 
detection and supporting CASE tools.
100 ms resolution is very easy.

I will post a lengthy description of K1.  Contact 
me via e-mail, phone or fax for more information.

I hope this helps.

Sam Harbaugh  SAHARBAUGH@ROO.FIT.EDU
---
Newsgroups: comp.lang.ada
From: wellerd@ajpo.sei.cmu.edu (David Weller)
Subject: Re: Multiple Inheritance -- the last post?
Organization: Ada Joint Program Office
Date: Thu, 20 Aug 1992 11:45:52 GMT

In article <9208191557.AA09135@efftoo.boeing.com> crispen@efftoo.boeing.com (crispen) writes:
>It's now been two weeks since I asked people who had actually used
>[etc.]
>people who think MI is a Good Thing, and who have experience to back
>up that judgement, to come forward.  Come on, one last time, or let's
>consider MI a plaything, not worthy of the attention of serious people.
>
Have you crossposted to comp.lang.c++ and comp.object?  I didn't see
that on the header above.  I believe that MI is useful, but I also
believe that the 9X solution is reasonable.  As Grady Booch has said,
multiple inheritance is like a parachute -- you don't always need it,
but when you do, you're quite happy to have it.

Dave Weller
wellerd@ajpo.sei.cmu.edu

>Bob Crispen
>crispen@foxy.boeing.com


Newsgroups: comp.lang.ada
From: bhanafee@deimos.ads.com (Brian Hanafee)
Subject: Verdix support [was Re:  Sun/Verdix circular elaboration revisited]
Organization: Advanced Decision Systems, Mountain View, CA 94043, +1 (415)
	960-7300
	<1992Aug14.150935.18824@src.honeywell.com>
Date: Fri, 14 Aug 1992 17:58:37 GMT


In article <1992Aug14.150935.18824@src.honeywell.com> tap@src.honeywell.com (Thomas A Peterson) writes:
>> About 2 weeks ago I complained ( to put it lightly ) about Sun/Verdix
>> Ada and a circular elaboration problem. Well , next morning I had 6
>> e-mails and a phone call , some from Verdix some from Sun . These
>> people must have worked the weekend to work on my problem and get me a
>> tape by next wednesday.
>
>I am impressed. Do you think if I yelled and screamed that I would get
>the same results? Everytime I send a bug report to Verdix I receive an
>acknowledgement within a months time saying that they received the bug
>report.  After about nine months I receive another acknowledgement
>saying that it is indeed a bug. I have never ever received an
>acknowledgement saying that 'Yes, we fixed the problem!'
>

Two suggestions:

First, give them a call.  I have gotten good response from Verdix by
calling and asking what the status of a report is.  They are
responsive if you are willing to work with them.  On one occasion, I
was unable to reproduce a bug outside of my own (rather complex)
system.  Their customer support person logged on to my system, I
brought my system up, and she seized the running process using the
debugger and was able to observe the bug occur and identify the
problem.  I had a concise description and a workaround within a week.

Second, they have a bugs BBS.  I've never used it, but it might be
helpful if you want to know what the known bugs in the system are, and
what workarounds have been identified.  (I wish *every* software
vendor had one of these...).  The number they gave me for the BBS is
(703) 318-5898.

>BTW, is there a FAQ around that contains a list of Ada compiler
>vendors.

I believe the FAQ contains a pointer to the ftp site ajpo.sei.cmu.edu,
which contains a list of all the validated Ada compilers along with
contact information for each of the vendors.

--
Brian Hanafee                         Advanced Decision Systems
bhanafee@ads.com                      1500 Plymouth Street
(415) 960-7300                        Mountain View, CA 94043-1230
From: gt1827a@prism.gatech.EDU (david daniell)
Newsgroups: comp.lang.ada
Subject: Writing an interrupt handler
Date: 17 Aug 92 16:56:19 GMT
Followup-To: gt1827a@prism.gatech.edu
Organization: Georgia Institute of Technology

I am currently using Alsys Ada v4.4.2, and need to write an interrupt
handler for the PC.  I am new to this area of programming (I have
been using Ada for about two months and have never programmed 
interrupts or in Assembly Language).  The section (13.5.1) of
the LRM doesn't really clarify much, and the chapter Handling 
Hardware Interrupts in "Application Developer's Guide" isn't 
much clearer to me.  I would really appreciate any pointers
on where to start looking (for books, etc. to help me learn), or
any tips on how to go about this.  The handler shouldn't be
system specific (should use only standard Ada).

Thanks.

-- 
David Daniell
Georgia Institute of Technology, Atlanta Georgia, 30332
uucp:	  ...!{decvax,hplabs,ncar,purdue,rutgers}!gatech!prism!gt1827a
Internet: gt1827a@prism.gatech.edu
Newsgroups: comp.lang.ada
From: tap@src.honeywell.com (Thomas A Peterson)
Subject: Re: Sun/Verdix circular elaboration revisited
Organization: Honeywell Systems & Research Center
Date: Fri, 14 Aug 1992 15:09:35 GMT

> About 2 weeks ago I complained ( to put it lightly ) about Sun/Verdix
> Ada and a circular elaboration problem. Well , next morning I had 6
> e-mails and a phone call , some from Verdix some from Sun . These
> people must have worked the weekend to work on my problem and get me a
> tape by next wednesday.

I am impressed. Do you think if I yelled and screamed that I would get
the same results? Everytime I send a bug report to Verdix I receive an
acknowledgement within a months time saying that they received the bug
report.  After about nine months I receive another acknowledgement
saying that it is indeed a bug. I have never ever received an
acknowledgement saying that 'Yes, we fixed the problem!'

BTW, is there a FAQ around that contains a list of Ada compiler
vendors.

Tom
Newsgroups: comp.lang.ada
From: dsoulele@uccs.jpl.nasa.gov (Dean Souleles)
Subject: Memory leak in Ada/X bindings
Originator: dsoulele@uccs
Organization: Jet Propulsion Laboratory, Pasadena, CA
Date: Thu, 20 Aug 1992 18:42:11 GMT

In article <1992Aug14.144015.17168@u.washington.edu> sinan@milton.u.washington.edu (Sinan Karasu) writes:
>
>   
>In the following code ( which is from Stars Xlib bindings) the lines
>flagged by -- sjw are needed in an Alsys environment, 
>since otherwise we end up a memory leakage problem .. What does LRM say 
>about this? is this a bug or normal ? is there a simple way to take care 
>of this? Any suggestions are heartily welcome.
>-------------------------------------------------------------------------
>
>      function set_event
>          (untyped_event_record : x_crossing_event_record) return event_record
>          is
>         untyped_event : x_event :=
>            new x_crossing_event_record'(untyped_event_record);
>
>         procedure free is new unchecked_deallocation -- sjw
>           (object => X_Crossing_Event_Record,        -- sjw
>            name   => X_Event);                       -- sjw
>
>      begin
>         case event_type'val (untyped_event.kind) is
>            when button_press  =>
>               declare
>                  the_x_event : x_button_event :=
>                     to_x_button_event (untyped_event);
>               begin
>                  free(untyped_event); --sjw
>                  return
.
.
.
>  --- Thanx for your help
>      Sinan


This fix is incorrect.  The unchecked conversion: 

    the_x_event : x_button_event :=
        to_x_button_event (untyped_event)

and all of the other similar ones, simply convert one acess type to another.
After this unchecked conversion the variable the_x_event and untyped_event
are access types that point to the SAME memory. You cannot then free the 
untyped_event because it the memory is referenced via the the_x_event pointer
in the return statements for each case.

Here is how I fixed the memory leak:

    function To_X_Event is new Unchecked_Conversion
                                  (Source => System.Address, Target => X_Event);

    function Set_Event (Untyped_Event_Record : X_Crossing_Event_Record)
                       return Event_Record is

        Untyped_Event : X_Event := To_X_Event(Untyped_Event_Record'address);

    begin
        case Event_Type'Val (Untyped_Event.Kind) is
            when Button_Press =>
                declare
                    The_X_Event : X_Button_Event :=
                       To_X_Button_Event (Untyped_Event);


This eliminates the the "new" that was allocating the memory in the first
place and does not leak.

This code has been implemented in the JPL Ada/Motif bindings.

Dean.
--
Dean Souleles
dsoulele@uccs.jpl.nasa.gov
Jet Propulsion Laboratory
-- 
Dean Souleles			dsoulele@uccs.jpl.nasa.gov
				dsoulele@dsfvax.jpl.nasa.gov

Jet Propulsion Laboratory
Newsgroups: comp.lang.ada