HDTenEightyP/NetNews huggingface dataset:
From: davep@paladin.corp.sgi.com (David Packer)
Newsgroups: comp.lang.c++
Subject: RPC on SGI
Date: 20 Nov 92 19:14:57 GMT
Organization: Silicon Graphics Inc., Mountain View, CA
NNTP-Posting-Host: paladin.corp.sgi.com

Howdy,

Anyone know where I can get RPC classes that compile on an 
SGI machine running IRIX 4.0.1 or greater??

Any help would be greatly appreciated..!!!!...

Thanx..

Dave.
Newsgroups: comp.lang.c++
From: frank@Cookie.secapl.com (Frank Adams)
Subject: Re: Idempotent header file proposal
Date: Sat, 21 Nov 1992 17:54:56 GMT
Organization: Security APL, Inc.

In article <1992Nov20.010009.24900@taumet.com> steve@taumet.com (Steve Clamage) writes:
>nh@cbnewsg.cb.att.com (nicholas.hounsome) writes:
>>Can we not have a standard pragma to say that a header file is idempotent
>
>This solves a problem outside the language, and for that reason is
>probably not appropriate to put in the language Standard. [...]
>
>Many people involved with standards efforts believe that there should
>not be such a thing as a "standard pragma".  A pragma by its nature
>controls something non-standard, non-portable, or system-specific.
>If the thing controlled were generally portable, it should probably
>be a language feature, not a pragma.

You appear to be contradicting yourself here.  This is a generic problem; it
does *not* apply only to some systems.  So a standard is appropriate; but if
it is neither to be a language standard nor a standard pragma, how is it to
be done?

>  In
>particular, you are assuming that a standard header is a file, and
>that it is read and processed by the compiler in the way user text
>files are processed.

No, the proposal is for a pragma to be placed in the include file.  As such,
it is directly applicable only to user-defined headers, which must indeed be
files.  Of course, this would in no way prevent compiler-writers from using
it for standard headers, if it was appropriate.
From: je@unix.brighton.ac.uk (John English)
Newsgroups: comp.lang.c++
Subject: Re: Wanted: Real Example of MI
Date: 23 Nov 92 09:02:10 GMT
Organization: University of Brighton, UK

In article <1992Nov19.101210.1@happy.colorado.edu> you write:
: I am revising a course on C++.  I have been looking for some examples of
: multiple inheritance for some time now.  I look thru the plethora of C++ books
: at the local book stores and so far, I have yet to encounter one that has a
: good example of multiple inheritance.
: 
: Can any one give me a reasonable example of MI that is
: semantically consistent, concise and short AND REAL? 	

(I tried to reply by mail but it got bounced. "happy.colorado.edu" doesn't
exist according to our machine, so I'm posting this as a followup instead).

Reluctant as I am to give away trade secrets :-) I use a BankAccount
example in my C++ courses for this.  The base class BankAccount has
an account number generated from a static member, a list of Transactions
(a private friend class), account name (a String) and a current balance.
Member functions are: statement(), balance(), account_number(),
account_name().

The important bit is transaction(String payee, Date when, float amount)
which returns True if the transaction is successful (always is with
the base class -- no overdraft limit!).

From this I derive CurrentAccount which imposes an overdraft limit :-(.
All this needs is an overdraft limit data member, a setOverdraft ()
member, and a new constructor and transaction().  The new transaction()
just validates the transaction against the overdraft limit and then calls
BankAccount::transaction().

Similarly I derive an ChargingAccount which costs a fixed amount per
transaction. Then I multiply derive from these to give me a current account
which imposes transaction charges.  Then I point out that BankAccount needs
to be a virtual base class since I'm accumulating charges in a different
account from the one I'm withdrawing from!

I agree, there aren't many examples in textbooks. Try this one.
I can squirt you the source if you want.
-- 
-------------------------------------------------------------------------------
John English			| "Yes, understanding today's complex world of
Dept. of Computing		|  the future IS a little like having bees live
University of Brighton		|  in your head... but, there they are..."
Janet: je @ unix.brighton.ac.uk	| "People who live in windowed environments
Fax:   0273 642405		|  shouldn't cast pointers"
-------------------------------------------------------------------------------
From: gs4t@virginia.edu (Gnanasekaran Swaminathan)
Newsgroups: comp.lang.c++
Subject: Re:  sizeof( data member )
Date: 19 Nov 92 00:22:01 GMT
Organization: University of Virginia

john@bnrmtl.bnr.ca (John Hickin) writes:
:     class Foo
:     {
:             char Data[ 200 ];
:     public:
:         static void foo( int );
:         ...etc.
:     };
: 
:     void Foo :: foo( int needed )
:     {
:         if ( !(needed <= sizeof(Foo::Data)) ) complain();
:     }
: 
: Of course I can use the enum { Size = 200 } to work around the problem.
: The question is, should the langauge allow you to take the size of a
: data member without having an object in hand?

You can do
	sizeof(Foo().Data)
to find out the size of member Data. It works in gcc 2.2.2
after you provide a default constructor to class Foo.

-Sekar
Newsgroups: comp.lang.c++
From: dgreen@sti.com (Dan R. Greening)
Subject: Re: New Employee Test
Organization: Software Transformation, Inc.
Date: Wed, 18 Nov 1992 19:39:38 GMT

assist@orion.oac.uci.edu (ASSIST Coordination Site) wrote:

>i am in the process of hiring 2 C++ programmers.  This Wednesday 11/18/92
>we are conducting the final interviews with 4 candidates.

The problem is interesting, and after a minute or two I figured it out.
However, I'm not sure whether you will get what you want by doing a 
programming test.  

First, when I first looked at it, I wasn't sure that I could figure it 
out, but I have written reference-counting envelope/letter classes (whose
envelope class fits in 4-bytes), a flexible and efficient AVL tree 
template, etc.  Isn't that the kind of creativity you would seek, and not 
whether someone knows about the default copy constructor?

Second, I get kind of annoyed when people run me through a test
like that: it makes me think that I'm working with someone who can't tell
whether I know C++ through some other means.  I once had a recruiter from
Goodyear tell me that he would be giving me "the Brown test", whatever that
is, to determine how good a programmer I was (you would think my 92 percentile
on the CS GRE exam would have been sufficient).  I never called the
Goodyear rep back, because I don't think I want to work in an environment
like that (untrusting, incompetent, etc.).

Third, whether someone understands the picayune details of a programming
language tells me nothing of their productivity, and their ability to work
with others.  These are things that must be ferreted out.
-- 
____
\  /Dan Greening    Software Transformation   1601 Saratoga-Sunnyvale Rd, #100
 \/dgreen@sti.com   (408) 973-8081 x313       Cupertino, CA 95014
Newsgroups: comp.lang.c++
From: jjamison@bellahs.com (John Jamison RD AC)
Subject: ostream or ostream_withassign
Organization: Bell Atlantic Healthcare Systems
Date: Thu, 19 Nov 1992 04:33:32 GMT

I'm getting an "Illegal Instruction" crash in a program. The situation
is a function, void foo_print(ostream& o). The caller is calling
foo_print(cerr).  In foo_print, the illegal instruction occurs during
a statement like o << "Some message text\n";  

With a symbolic debugger (pdb) I look at cerr and o. In the caller,
the debugger tells me that cerr is an instance of ostream_withassign.
In foo_print() it tells me that o is of type ostream. They resolve to
different addresses.

Has anyone else had similar problems (Sun-SPARC, with CenterLine c++)?
Just what is the difference between an ostream_withassign and an ostream?

-John Jamison

-- 
/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
John Jamison
Bell Atlantic Healthcare Systems
From: jones@colisd.COLONIAL.COM (Libby Jones)
Newsgroups: comp.lang.c++
Subject: object oriented class library
Date: 17 Nov 92 18:20:30 GMT
Reply-To: jones@colisd.UUCP ()
Organization: Colonial Management, Boston

I am posting this question for a friend.  If you have an
answer to her question please call her.  She does not yet
have any computers where she works.  please call KitKoon Chan
at 617-434-3497.  Thankyou.

Are there any object oriented class librarys for banking and
financial applications such as an account object for a customer
account, and ATM object for ATM transactions?  Who are the vendors
of these libraries?

Newsgroups: comp.lang.c++
From: se_rossb@rcvie.co.at (Bernhard Rossboth)
Subject: Re: Multiple Header Files Problem
Reply-To: se_rossb@rcvie.co.at
Organization: Alcatel ELIN Research
Date: Thu, 19 Nov 1992 15:36:20 GMT


>In <5189@holden.lulea.trab.se> jbn@lulea.trab.se (Johan Bengtsson) writes:
>
>>Problem is that a.hh gets #included, #includes b.hh, which tries to
>>#include a.hh.  This will fail, since b.hh will not see all declarations
>>in a.hh (A_HH is already defined).
>

Maybe a solution to your dilemma is using inside of the header file for at least
one of the two classes only pointers or references to objects of the other type.
Doing so there is no need to include the header file (e.g. b.hh) inside the header 
file of the other class (a.hh), but only in a.cc you have to really include b.hh. 

An example will show you what I mean:

-----------   a.hh -------------
class B;                        // There is a class B somewhere around 

class A {
		B *bp;          // Pointer to an existing class is fine, but:
// 		B theB; 	   would not work!! How much space needs a B???
	public:
		void useB(B&b); // Reference to an existing class is fine
};

------------ end of a.hh --------

------------  b.hh --------------
#include <a.hh>			// must include parents definition!

class B: public A {
	public:
		int i;		// just some junk of no interest
		B() { i= 1;}
};

------------ end of b.hh ---------

------------  a.cc ---------------

#include <b.hh>                 // now I have to know all methodes and members of B

void A::useB(B &b)
{
	cout << b.i;
}
------------ end of a.cc ---------

							Barny :-{)

PS: Using pointers instead of static members and declaring the classes instead of
including the header files may reduce the compile-time of your project significant!

Newsgroups: comp.lang.c++,comp.object
From: jimad@microsoft.com (Jim Adcock)
Subject: Re: How do you sell OOP to management?
Date: 20 Nov 92 19:54:19 GMT
Organization: Microsoft Corporation

In article <1992Nov18.164904.23635@ucsu.Colorado.EDU> lewisc@ucsu.Colorado.EDU (Christopher J. Lewis) writes:
|procedural programing to OO programming.  Since many of our managers are not
|programmers, we are at somewhat of a loss on how to justify the switch.

In my humble experience, the only practical way to change one's management
is to change one's management.  

If one's management doesn't know programming, what chance do they have of 
successfully knowing OOP?  Watch out -- lest you become the scapegoat
for their incompetence.

IMHO only.
Newsgroups: comp.lang.functional
From: marc@techfak.uni-bielefeld.de (Marc Rehmsmeier)
Subject: CONTRAINDICATIONS
Date: Tue, 17 Nov 1992 14:29:42 GMT
Organization: Universitaet Bielefeld, Technische Fakultaet.


Consider the following Haskell-definitions (maybe you recognize it =>
"Is efficient backtracking feasible in functional languages?"):

strangesucc :: Int -> Int
strangesucc n = head [x | x <- [0..], x > n]


Evaluating main = print (strangesucc n)
we obtain the following table:

n      | GCs | alloc    | user | mx   | id     
-------+-----+----------+------+------+-------
100000 | 30  |  6001368 | 1.25 |  240 |  29927   overloaded 
200000 | 61  | 12001368 | 2.42 |  242 |  59174 

100000 |  3  |  2401236 | 0.81 | 1189 |  72767   non-overloaded
200000 |  3  |  4801236 | 1.29 | 1762 | 173179 


Comparing the overloaded with the non-overloaded
definition we obtain:

                 | overloaded | non-overloaded
-----------------+------------+---------------
 1) GCs          | high       | low
    depends on n | yes        | no
 2) alloc        | high       | low
 3) user         | high       | low
 4) mx           | low        | high
    depends on n | no         | yes
 5) id           | low        | high


My questions:

1. Why do the two functions (with and without
   type signature) show opposite behaviour?

2. Why do alloc and mx/id show opposite behaviour?


Marc Rehmsmeier.

-------------------------------------------------------------

GCs   = number of garbage-collections (STAT-file)
alloc = bytes allocated from heap (STAT-file)
user  = user time used (rusage)
mx    = maximum resident set size (rusage)
id    = integral resident set size (rusage)
Newsgroups: comp.lang.functional
From: farrell@coral.cs.jcu.edu.au (John Farrell)
Subject: The end of space leaks as we know them
Keywords: lazy backtracking Gofer
Organization: James Cook University
Date: 17 Nov 92 04:04:46 GMT

In <BxM80r.1Hu@dcs.glasgow.ac.uk> kh@dcs.glasgow.ac.uk (Kevin Hammond) writes:
>Most functional language implementations that I know in detail (strict
>or non-strict) have, or have had, significant space-leak problems.

  I am not a functional language implementor, so please pardon my ignorance
about space leaks, but here is something that might be very important. On page
123 of IEEE Software, September 1992, is an article about a product called
Purify for debugging memory management in C and C++. The author of the article
cannot speak highly enough of it. This may be just the thing to eliminate
space leaks forever.
  For more information, it appears you can email to info@pure.com.


John
Newsgroups: comp.lang.functional
From: waugh@probitas.cs.utas.edu.au (Sam Waugh)
Subject: Matrix operations in Haskell
Organization: University of Tasmania, Australia.
Date: Thu, 19 Nov 1992 04:35:01 GMT

Hi.

Just wondering if anyone has an efficient implementation of matrix
operations in Haskell?

Thanks.

Sam.
email: waugh@cs.utas.edu.au
From: sewardj@cs.man.ac.uk (Julian Seward (DRL PhD))
Newsgroups: comp.lang.functional
Subject: Re: Is efficient backtracking feasible in functional languages?
Date: 13 Nov 92 09:54:50 GMT
	<BxM80r.1Hu@dcs.glasgow.ac.uk>
Organization: Department of Computer Science, University of Manchester
In-reply-to: kh@dcs.glasgow.ac.uk's message of 12 Nov 92 18:14:49 GMT


Kevin Hammond writes:

| The Haskell B. (and LML) implementations have (or had) some
| interesting space leaks (as Dave Wakeling's profiler pointed out).
| One of these was due to not "black-holing" closures when they were
| entered (so retaining space if arguments to the original closure
| became dead before the closure was fully evaluated).  It sounds as if
| this may be the problem reported with the Haskell B implementation.
| The most recent implementation has compiler flags to fix the problems
| which Dave Wakeling reported, but I think they're disabled by default
| (black-holing costs time, for instance, which you may not want to
| spend).

I thought the 0.998.* versions of lml/hbc have blackholing
*on* by default.  Anyway, you can turn it on manually
by issuing the flag -fzap-redex to lml or hbc.

I suspect blackholing doesn't cost more than about 5% in performance
terms, but it would be interesting for someone to quantify this.
As I understand it, the Glasgow compiler maintains a stack of
pointers to closures under evaluation, so the garbage collector
can do the redex zapping, rather than impose that cost on the
mutator.  lml/hbc unfortunately has to zap every closure as it
goes along, which is more expensive.

Jules
Newsgroups: comp.lang.functional
From: urban@daimi.aau.dk (Urban Engberg)
Subject: Re: Including files from ml-lex and -yacc
Keywords: ml-lex ml-yacc sml
Organization: DAIMI: Computer Science Department, Aarhus University, Denmark
Date: Wed, 18 Nov 92 09:50:39 GMT

Thanks for all advice.  David Tarditi sent me some ml-code
implementing a stack of lexers, doing the job brilliantly.   Whenever
lex meets an include directive, it runs a new lexer on the include
file and pushes itself on the stack etc.  I would be happy to
distribute it to whoever is interested.

  Urban
From: asgeir@viking.asd.sgi.com (Asgeir Eiriksson)
Newsgroups: comp.lang.functional
Subject: Standanrd ML of NJ on SGI IRIX 4.0.1
Date: 17 Nov 1992 15:44:27 GMT
Organization: Silicon Graphics, Inc.  Mountain View, CA
NNTP-Posting-Host: viking.asd.sgi.com

Anyone out there in netland install Standard ML of NJ on an SGI machine
running IRIX release 4.0.1?

When I run 'makeml -sgi irix' it doesn't compile. I'd like some feedback
from the net before I try to fix the Makefiles, etc. 

Thanks, 'Asgeir
Newsgroups: comp.lang.functional
From: brent@ssd.csd.harris.com (Brent Benson)
Subject: Re: The end of space leaks as we know them
Organization: Harris Computer Systems
Date: Tue, 17 Nov 1992 14:53:50 GMT
	<1992Nov12.162725.25836@cs.yale.edu> <BxM80r.1Hu@dcs.glasgow.ac.uk>
	<farrell.721973086@coral>

farrell@coral.cs.jcu.edu.au (John Farrell) writes:

> On page 123 of IEEE Software, September 1992, is an
> article about a product called Purify for debugging memory
> management in C and C++. 

> This may be just the thing to eliminate space leaks forever.

Yeah, that's the ticket.  Eliminate space leaks...forever ;-).
Seriously though, let's not go off the deep end.  Purify is just a
tool, not a panacea.

--
Brent Benson                     
Harris Computer Systems
From: augustss@cs.chalmers.se (Lennart Augustsson)
Newsgroups: comp.lang.functional
Subject: Re: Is efficient backtracking feasible in functional languages?
Keywords: lazy backtracking Gofern
Date: 17 Nov 92 04:20:26 GMT
Organization: Chalmers University of Technology

The Haskell program
	ss n = head [ x | x<-[0..], x>n ]
does indeed use linear space with hbc 0.998.5.  The reason for this is
that all Prelude functions (in this case head) are compiled without
overwriting the root redex.  If you define your own head function
the program runs in constant space (416 bytes to be exact).  The reason for
not overwriting the root redex has nothing todo with efficiency 
consideration; "zapping" the redex only takes about 3% longer.
The reason is that I wanted the Prelude functions to work with
the interactive system.  Zapping (blackholing) does not work well with
the interactive system because here you can interrupt computation with ^C
(admittedly not entirely clean), and the graph should be in a consistent
state if you do.  Having black holes around makes it inconsistent (or at least
unusable).  
I hope to have the Prelude compiled with zapping in the next release.

-- 

	-- Lennart Augustsson
[This signature is intentionally left blank.]
From: johnsson@cs.chalmers.se (Thomas Johnsson)
Newsgroups: comp.lang.functional
Subject: Invitation to visit the fp group at Chalmers
Date: 23 Nov 92 09:17:29 GMT
Organization: Dept. of CS, Chalmers, Sweden




An Invitation to Visit the Functional Programming Group
=======================================================
        at Chalmers University, Gothenburg
        ===================================

The functional programming group at Chalmers University of Technology
has funding to invite one or more medium-term visitors during the
coming year. Visits may be from three to twelve months duration, and
the visitor will be paid a tax-free fellowship of 12,000 SEK per
month, or your additional costs if you take a sabbatical to come.
Visits should preferably begin before the end of June 1993.  Visitors
must have a doctorate, and must be coming from outside Sweden to
be eligible for a fellowship.

The salary of 12,000 SEK per month is approximately US$22,000 or
UK#14,500 per year.  It is sufficient for one person to live
comfortably in Sweden.

The functional programming group consists of Lennart Augustsson, John
Hughes, Thomas Johnsson, Mikael Rittri, Mary Sheeran, and about a
dozen others. Current research includes:

*	Efficient implementation of lazy functional languages.
*	Parallel graph reduction.
*	Programming environments for functional languages, including 
	window interfaces.
*	Garbage collection.
*	Program analysis by abstract interpretation.
*	Partial evaluation.
*	Relational programming and hardware algorithms.
*	Architectures to support functional languages.
*	User defined syntax.

If you are interested in visiting us, please contact John Hughes
(rjmh@cs.chalmers.se) or Thomas Johnsson (johnsson@cs.chalmers.se)
by 11 December.

	-- John Hughes,  Thomas Johnsson

-- 
Thomas Johnsson  (johnsson@cs.chalmers.se)
Dept. of CS, Chalmers University of Technology, S-412 96 Goteborg, Sweden
phone: dept: +46 (0)31 721088.
Newsgroups: comp.lang.functional
From: wolfe@sequent.com (David Wolfe)
Subject: looking for Standard ML of New Jersey  
Organization: Sequent Computer Systems, Inc.
Distribution: us
Date: Fri, 20 Nov 92 01:29:31 GMT

I'm probably getting to be a real pain now. Thanks to all who replied to my
request for ifp. Got it. Thanks again.

Now I am looking for Standard ML of New Jersey. 

Is there an FTP site for it?

Many thanks again,
			-DaveW

PS. I don't know why I have two signatures
-- 
|    ,__o  | In mondo caeco,   |    ,__o  |    wolfe@sequent.com   |  o__,    |
|  _-\_<,  | luscus regnat.    |  _-\_<,  | ..!uunet!sequent!wolfe |  ,>_/-_  |
| (*)/'(*) |                   | (*)/'(*) |    (503) 578-4395      | (*)`\(*) |

-- 
|    ,__o  | In mondo caeco,   |    ,__o  |    wolfe@sequent.com   |  o__,    |
|  _-\_<,  | luscus regnat.    |  _-\_<,  | ..!uunet!sequent!wolfe |  ,>_/-_  |
| (*)/'(*) |                   | (*)/'(*) |    (503) 578-4395      | (*)`\(*) |

Newsgroups: comp.lang.functional
From: jas@munta.cs.mu.OZ.AU (John Shepherd)
Subject: Pure FP's Place in the History of Programming Languages
Organization: Computer Science, University of Melbourne, Australia
Date: Fri, 20 Nov 1992 00:46:22 GMT

Does anyone know why there is no representation from the pure (or almost
pure) functional school (ML, Miranda, Haskell, etc.) in the History of
Programming Languages Conference? The Conference purports to empahsise the
period from the last HOPL Conference (1978) until now, and I would have
thought that PFP had seen most of its development in that period.

Is this an optimistic sign that PFP represents future history? The New
Wave of programming? :-)

Cheers, jas
Newsgroups: comp.lang.functional
From: wg@opal.cs.tu-berlin.de (Wolfgang Grieskamp)
Subject: Re: Is efficient backtracking feasible in functional languages?
Followup-To: comp.lang.functional
Reply-To: wg@cs.tu-berlin.de
Organization: Technical University of Berlin
Date: Mon, 16 Nov 1992 23:02:09 GMT

rabin@CS.Yale.Edu (Dan Rabin) writes:

>Wolfgang Grieskamp refers to a scheme for converting a stream into an
>efficient imperative counter.  
>
>Readers of this newsgroup may wish to compare this work with the work
>of Dick Waters [1], which has been implemented in both Lisp and Pascal
>environments.  A Lisp interface to such a facility is documented in
>[2], Appendix A, pp. 923-955.

I unfortunately have to point out that comparsion is not possible
since the work I referred to is unpublished. The references I gave
describe the general framework in which the mentioned scheme can be
easily embeded as I believe.

Just to avoid misunderstandings.

--
Wolfgang Grieskamp
wg@cs.tu-berlin.de
From: ark@alice.att.com (Andrew Koenig)
Newsgroups: comp.lang.functional
Subject: Re: Including files from ml-lex and -yacc
Keywords: ml-lex ml-yacc sml
Date: 16 Nov 92 18:01:55 GMT
Article-I.D.: alice.24207
Reply-To: ark@alice.UUCP ()
Organization: AT&T Bell Laboratories, Murray Hill NJ

In article <farrell.721895635@coral> farrell@coral.cs.jcu.edu.au (John Farrell) writes:

>   I thought the standard way to do this was to use the same compiler
> directives as C does, then use the C preprocessor :-). It's a hack, I know,
> but it provides a well-known set of functions at very low cost.

Just make sure you don't utter the names of any macros in your ML comments.
-- 
				--Andrew Koenig
				  ark@europa.att.com
Newsgroups: comp.lang.functional