HDTenEightyP/NetNews huggingface dataset:
From: wiml@milton.u.washington.edu (William Lewis)
Subject: Re: Error detection/reporting
Organization: University of Washington
Date: Mon, 21 Dec 1992 07:35:51 GMT

mcook@fendahl.dev.cdx.mot.com (Michael Cook) writes:
>Yes, me too.  It would seem natural that operations like open() and print()
>should produce fatal errors if they couldn't do what you asked.  How often do
>you want to do anything other than die when open() fails?  How often do you
>want to ignore an I/O error?  Hm...

Well, I not too infrequently want to be able to handle errors on open(),
but it's not often that I want to try to recover (or even have an idea
how I SHOUDL recover) from an error in "print". Maybe there should be an
option that could be set to make all errors in print automatically fatal.
Better yet, a magic associative array, vaguely like the %SIG array:

   %ERR{'print'} = die;
   %ERR{'close'} = warn;
   %ERR{'getpid'} = mysub;

sub mysub
{
   die "No parent process? What am I, the kernel?\n";
}

   perhaps some arguments could be passed to the error handler ... the
return value from the handler (if it returns) could be used as the return
value from the print/close/getpid call or maybe there should be a way to 
indicate that the call should be tried again ... also, if the error
handling subroutine called because of a 'vec' returns the value -41,
then perl shuld jump to a special routine which will calculate pi
and print the results, in base 11, to file descriptor 8.  :-)

   okay, so maybe I got carried away there ...


(print "Just another perl hacker,\n") || warn "Couldn't JAPH";
-- 
email: wiml@u.washington.edu             |  Home:  Seattle, Washington   |
     (William Lewis)                     |  47 41' 15" N   122 42' 58" W | 
NeXTmail: wiml@ingalls.cs.washington.edu `-------------------------------'
        --*-- Member, Coalition to Preserve Semantic Vacuity --*--
From: dnb@meshugge.media.mit.edu (David N. Blank-Edelman)
Newsgroups: comp.lang.perl
Subject: Perl on Solaris 2.1 w/GCC
Date: 30 Dec 92 22:52:34 GMT
Organization: M.I.T. Media Laboratory

Howdy-
  I've been having no fun at all attempting to build 4.035 under
Solaris 2.1 using the Catalyst CD version of GCC.  Has anyone done
this recently who would be willing to share the incantation?  Thanks.
        Peace,
             dNb
--

 David N. Blank-Edelman              o/    \  /    \ /     /      \o   
 M.I.T. Media Laboratory            /#      ##o     #     o##      #\
 E15-473F, (617) 253-2169           / \    /  \    /o\    / |\    / \
Newsgroups: comp.lang.perl
From: Prasad Alavilli <prasad@stro5.vub.ac.be>
Subject: Curseperl on HP 730
Reply-To: prasad@stro5.vub.ac.be
Organization: The Internet
Date: Tue, 29 Dec 1992 09:58:30 GMT


Hi guys..

I am trying to make "curseperl" in the usub directory of the Perl-035
distribution but get the following error:

|> make
        cc -c -I..  -DDEBUGGING -g usersub.c
        mus curses.mus >curses.c
        cc -c -I..  -DDEBUGGING -g curses.c
        cc ../uperl.o usersub.o curses.o -lcurses -ltermlib `. ../config.sl
/bin/ld: Unsatisfied symbols:
   touchline (code)
*** Error code 1

I am on a HP9000 730 series machine.
Does someone out there see the problem? Your help would be appreciated.

Prasad
prasad@stro5.vub.ac.be
Newsgroups: comp.lang.perl
From: utashiro@sran230.sra.co.jp (Kazumasa Utashiro)
Subject: Re: Looking for a "numerical/alpha" sort routine.
Organization: Software Research Associates, Inc., Japan
Date: Thu, 24 Dec 1992 03:21:24 GMT

In article <1992Dec23.193120.25893@pool.info.sunyit.edu>
	buck@pool.info.sunyit.edu (Jesse Buckley) writes:
>> Does anyone have a sort/compare routine that will work for numerical
>> alpha data?  For example, if I have 1, 2, 3a, 3b, 3c, I want them sorted
>> that way.  Right now the <=> compare ignored the letters after the
>> numbers.  Thanks.

Next line works for your example.

@s = sort { $a <=> $b || $a cmp $b } ('3c', '1', '3a', '2', '3b');
print "@s\n";

--utashiro
Newsgroups: comp.lang.perl
From: essbaum@rchland.vnet.ibm.com (Alexander Essbaum)
Subject: Re: fork and STDOUT
Date: Thu, 31 Dec 1992 19:12:09 GMT
Disclaimer: This posting represents the poster's views, not necessarily those of IBM
Organization: IBM Rochester

it's amazing how much better my brain functions immediately after clicking
on "send".

so now i got the output in the right order (still buffered, but the "die"
printout comes after the STDOUT printout).

i moved the

	select(STDERR); $| = 1;
	select(STDOUT); $| = 1;

into the script called by $cmd.

still have to unbuffer the output, though.

axel
From: eric.arnold@sun.com (eric )
Newsgroups: comp.lang.perl
Subject: actually mnemonic special variable names
Date: 25 Dec 1992 01:18:17 GMT
Organization: Sun Microsystems, Inc.
Distribution: world
Reply-To: eric.arnold@sun.com
NNTP-Posting-Host: animus.corp.sun.com

Has anyone already written something that aliases all those special
variables (Camel book:  "You can say one thing for them -- they're
certainly concise.").  For example, the first element of the default
work variable is:

		$_[$[]	(obChurchLady: "Well, [pause] isn't that *speeecialll*!")
instead of:
	  	$WORK[$FIRST_ELEM]
or		$WORK[$F_EL]

or another eg.:	$OUTPUT_FIELD_SEPARATOR = "\t";
or		$OFS = "\t";

		In these cases, you might have the long and short alias
		for people with difference laconic leanings (or
		annoying alliterative abilities?).

This requires something like:  
	*WORK = *_;
	*F_EL = *[;
	*OUTPUT_FIELD_SEPARATOR = *<I can't remember>;
	*OFS = *<I can't remember>;
	
or maybe writing a function call package which references the
special variables directly.

I was starting to do this myself, but it seemed like a lot of typing,
and there might already be a set of aliases somewhere that people are
using that are semi-standard (E.g. "OFS" for output field separator.)

Also, would such an aliasing scheme work for the local special
variables?  I haven't tested many variables yet to see how they
behave.

There are two reasons that I want to do this:  1) because I can't
remember the mnemonics suggested by the camel book that supposedly help
one to associate punctuation and diacritical marks with Perl functions
(they were fun to read, but...), and 2) because it's really hard to
write semi-self-documenting/maintainable code with descriptive symbols
when crucial operations hinge around symbols which look like $, or
$_[$[] .


-Eric
Eric.Arnold@Sun.COM


P.S. I won't even suggest, lest I get into trouble, that such aliases be
added to Perl, either in "$NAME" form, or in another associative array,
like "%ENV" or "%SIG", like $BUILTIN{OFS} = "\t"; or $SPEC{OFS} or
$SV{OFS} or etc.

This is one of the things about Perl which can't "be done more than one
way".  You have to use these variables, and so your script must take on
their obfuscation (IMHO, they're the yuckiest part of Perl, the rest of
which has been steadily growing on me) even if you are trying to make
it look simple by keeping to C constructs, or using the
conversational-style modifiers, or whatever.  As far as I can tell,
this is one area of Perl where you don't have your choice about economy
of style (sans ubiquitous comments, of course).

Newsgroups: comp.lang.perl
From: thecure@ee.mu.OZ.AU (matthew aardvarkious)
Subject: [*] Bug ? WoRkarOuNd?
Organization: Electronic and Electrical Engineering - University of Melbourne 
Date: Sat, 2 Jan 1993 06:44:34 GMT

$RCSfile: perl.c,v $$Revision: 4.0.1.7 $$Date: 92/06/08 14:50:39 $
Patch level: 35

sub main'change_nick {
        local($oldnick,$newnick)=@_;
        foreach $key (keys(%chanop)) {
                $chanop{$key} =~ s/$oldnick/$newnick/;
        }
}
1;

That's the code that exits on me when..

	$oldnick = "foo\";

with the message..

  /_\/: trailing \ in regexp at s_change_nick.pl line 4, <> line 4336.

I don't want to edit the $oldnick string to comment it out, any suggestions?

Someone said if you're not careful
You'll have nothing left and nothing to care for

- Behavior, "Being Boring"
Newsgroups: comp.lang.perl
From: Rick Emerson <rick@ssg.com>
Subject: WANTED: how to sort a directory
Reply-To: rick@ssg.com
Organization: The Internet
Date: Mon, 21 Dec 1992 16:01:33 GMT

I have a directory filled with files (current count is over 2,000 files)
that have an eight digit (sequence) number as their name.  As new files are
added to the directory, old files may be removed from the directory.  Note,
however, not all old files are removed (files over 90 days old, for example,
are not automatically killed off).  I'm concerned that new (higher numbered)
files not appear in the directory interleaved with older, lower numbered
files.

Is there a simple, perl way to actually sort the files in ascending order?
For several reasons I want to avoid sorting a list of file names; the actual
directory must be guaranteed to have the file names in ascending order.

Rick


| Richard B. Emerson     | Replies may be sent to:                         |
| System Support Group   |                        rick@ssg.com             |
| 940 Delaware Avenue    |-------------------------------------------------+
| Lansdale, PA 19446 USA | "When you ski, you dance with the mountain --   |
| Voice: 215.855.1607    |  and the mountain always leads."                |
Newsgroups: comp.lang.perl
From: Tom Christiansen <tchrist@convex.COM>
Subject: Re: Arrgh: Looking for usenet news watcher
Originator: tchrist@pixel.convex.com
Date: Wed, 23 Dec 1992 06:30:47 GMT
Reply-To: tchrist@convex.COM (Tom Christiansen)
Organization: Convex Computer Corporation, Colorado Springs, CO
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.

From the keyboard of wiml@milton.u.washington.edu (William Lewis):
:A while ago, I saw a Perl script posted that would read news for me
:and (presumably) do something if an article was found that matched 
:certain criteria. 

Check out the 'clip' program on convex.com in /pub/perl/scripts/clip --
I think it's what you want.

--tom
-- 
    Tom Christiansen      tchrist@convex.com      convex!tchrist

    Just don't compare it with a real language, or you'll be unhappy...  :-)
            --Larry Wall in <1992May12.190238.5667@netlabs.com>
Newsgroups: comp.lang.perl
From: alanm@cognos.com (Alan Myrvold)
Subject: Re: Package & Namespace Question
Keywords: package, inheritance, perl 5
Organization: Cognos Incorporated, Ottawa CANADA
Date: Tue, 22 Dec 1992 15:30:15 GMT

In article <163@eiffel.eiffel.com> ram@eiffel.com (Raphael Manfredi) writes:
>I believe it is a desirable property to have all the classes (packages)
>inherit from one root class (package main), since the root class is the
>only possible repository for basic features which need to be seen by all
>the user-defined classes.
...
>Now, did I do a good job in convincing you?

No.

If class foo inherits from main, then presumably the function call
&foo'bar, or the variable $foo'baz, if not defined in package foo,
will refer to &main'bar or $main'baz.

This is wrong, given the way most people use packages.  Most perl programs
are fairly small, and clutter main' with variables and subroutines.  When
that clutter gets too messy, packages can be used to segregate the namespace.

If $main'baz and $foo'baz refer to the same thing, then there is no namespace
segregation.

And please, the pollution of namespace that Eiffel inheritance brings, and the
rename subclause that kludges a workaround have no place in the Perl package
system!

Perl is a different language, and deserves none of the defects of Eiffel.

---
Alan Myrvold          3755 Riverside Dr.    
Cognos Incorporated   P.O. Box 9707          alanm@cognos.com
(613) 738-1440 x3317  Ottawa, Ontario       
                      CANADA  K1G 3Z4       
Xref: sparky comp.lang.clos:1050 comp.lang.lisp:3148
From: marcoxa@IMAGE.CS.NYU.EDU (Marco Antoniotti)
Newsgroups: comp.lang.clos,comp.lang.lisp
Subject: CLOS Code Repository: Where is it?
Date: 28 Dec 92 09:04:15 GMT
Distribution: comp
Organization: New York University

The title is self explicative. I know it should be somewhere at Ohio
State, but I lost the pointer.

Sorry for the waste of bandwidth.

- Marco
Newsgroups: comp.lang.clos,comp.lang.lisp
From: mklai@ie.cuhk.hk (Edmund M K Lai)
Subject: LispView for Allegro CL
Organization: Faculty of Engineering, The Chinese U. of Hong Kong
Date: Wed, 30 Dec 1992 08:40:31 GMT

Has anyone got LispView 1.1 to work with Allegro CL 4.1?

Edmund Lai
Department of Information Engineering	phone: +852-609-7988
The Chinese University of Hong Kong	fax:   +852-603-5032
Shatin, N.T., Hong Kong			email: mklai@ie.cuhk.hk
Newsgroups: comp.lang.clos
From: peterson@sra.COM (Eric Peterson x7644)
Subject: <None>
Organization: The Ohio State University Department of Computer and Information Science
Date: Mon, 21 Dec 1992 14:46:37 GMT

Hi Marc;

   Although I read Sonya Keene's book as a non OOP beginner, I
remember thinking to myself that it would be a solid and
understandable OOP introduction.  See the FAQ for more book info.

   For what it's worth,


                                   Eric Peterson (speaking for myself)
                                   Systems Research and Applications
                                   2000 15th Street North
                                   Arlington, VA 22201
                                   USA
                                   peterson@sra.com
                                   (703) 558-7644
                                   Fax:  (703) 558-4723
From: bright@nazgul.UUCP (Walter Bright)
Newsgroups: comp.lang.c++
Subject: Re: Zortech C++ v3.1
Date: 30 Dec 92 07:42:30 GMT
Reply-To: bright@nazgul.UUCP (Walter Bright)
Distribution: usa
Organization: Zortech, Seattle

In article <1992Dec28.065134.16783@netcom.com> erc@netcom.com (Eric Smith) writes:
/Is version 3.1 of the compiler much different from 3.04, or does it
/mainly just add features?  Which of the bugs in version 3.04 have been
	It adds templates, AT&T 3.0 compatibility (no exception handling),
	precompiled headers, Multiscope debugger, Whitewater resource
	toolkit, Windows 3.1 support.
/fixed in version 3.1?  How much memory will the Windows version
	Over 500 bugs and enhancements have been done. QA has a list
	and they could tell you the specifics.
	Me, once I make an improvement and add it to the test suite
	I don't look backwards, I forget about it and move on to the
	next set of enhancements customers want.
/support?  3.04 was able to support a lot of memory by using old DOS
/software with VCPI, but was limited to 16 megabytes with Windows/DPMI.
/Does the new version still have that limitation, and does it still
/support more than 16 megabytes with VCPI?
	The Zortech DOS extender still supports DPMI, VCPI, XMS and bare
	metal. My understanding was that the 16Mb limitation was a limitation
	of Windows' DPMI implementation, not the DOS extender.
Organization: Arizona State University
Date: Tuesday, 22 Dec 1992 00:49:20 MST
From: <AUPCK@ASUACAD.BITNET>
Newsgroups: comp.lang.c++
Subject: Which C++ should I buy?

Hello!
    I'm in the market to buy a C++ but there are so many different company
offer one. I heard many good word about Borland's C++ but when I open the
magazine there is some other companies ads offers 32 bits C++. I didn't
remember Borland or MS said anything about 32 bits on their product. What
is the difference or should I wait for the next version. (after window NT?)
Any replies will be greatly appreciated.
                                                         Philip K.

Newsgroups: comp.lang.c++
From: dak@messua.informatik.rwth-aachen.de (David Kastrup)
Newsgroups: comp.lang.c++
Subject: Re: where the name C++ came from
Date: 25 Dec 92 06:29:34 GMT
Organization: Rechnerbetrieb Informatik - RWTH Aachen
Distribution: world
NNTP-Posting-Host: messua.informatik.rwth-aachen.de

tostan@dumbo.lerc.nasa.gov (Stan Mohler) writes:

>Hi-
>I had a dream last night in which I figured out a possible reason for C++
>having the name C++.  Yesterday I was reading about C and C++.  I skimmed
>across a few lines showing the use of operators such as ++.  i++ measns to
>increment variable i.  Incrementing something means to increase it, expand it
>if you will.  Is it possible that "C++" simply means an "expanded C" in the
>most economical and cute way a C programmer might think of?

Ingenious! What insight in the subtle train of thoughts of the foremost
computer language name designers! And that from somebody naming his
computer "dumbo"!

But really, for C programmers the name is absolutely obvious. The
increment operator is used very commonly, and so your post will cause
many people to groan.

Final thought: C++ does increase the value of C, but the increased value
is not used. Maybe ++C would have been the better choice... :)
Newsgroups: comp.lang.c++
From: maxtal@extro.ucc.su.OZ.AU (John MAX Skaller)
Subject: Re:  Give me safe C++
Organization: MAXTAL P/L C/- University Computing Centre, Sydney
Date: Mon, 21 Dec 1992 23:44:59 GMT

In article <1992Dec18.134937.14313@bony1.bony.com> richieb@bony1.bony.com (Richard Bielak) writes:
>
>If you are writing safety critical software - let's say software that
>controls the brakes in *my* car - I'd rather have you code in PASCAL
>and run with all the runtime checks on. I don't want my brakes to stop
>working just because you forgot an ampersand.
>
	I'd rather have the code
implemented in a language in which all the run-time checks
had been optimised away by PROVING they were not required.

	What would you have your brakes do if the run-time
checks detected a program error? I think if you lived
you would be entitled to sue the manufacturer.
-- 
;----------------------------------------------------------------------
        JOHN (MAX) SKALLER,         maxtal@extro.ucc.su.oz.au
	Maxtal Pty Ltd, 6 MacKay St ASHFIELD, NSW 2131, AUSTRALIA
;--------------- SCIENTIFIC AND ENGINEERING SOFTWARE ------------------
From: mjackson@gssec.bt.co.uk (Mark Jackson)
Newsgroups: comp.lang.c++
Subject: Re: prototyping object?
Date: 23 Dec 92 17:08:03 GMT
Followup-To: <1992Dec22.114524.421@ghost.dsi.unimi.it>
Organization: BT, Software Engineering Centre, Glasgow, Scotland


In article <1992Dec22.114524.421@ghost.dsi.unimi.it>,
 valentm@ghost.dsi.unimi.it (marco valentini) writes:
|> 
|> I have written the following code:
|> class paolo;  //!Is Right this ??????
|> object pippo
|> {
|>   paolo* p;
|>   public:
|>    void ....
|>    ..... (various methods)
|> 
|> }
|> object paolo
|> {
|>   pippo* pi;
|>   public:
|>    int ...
|>    ...(variuos methods)
|> }
|> 

Firstly, it is not recommended to have two classes mutually dependent on
each other.
i.e. pippo needs to know about paulo, and vice-versa. Check your design.

Secondly, there is nothing wrong with your 'forward declaration' of
class paulo.
What the compilation error sounds like is a module problem.
Separate the implementation from the class interface. i.e.

in file 'pippo.h'------------------------

class paulo;	// Forward declaration. O.K.

class pippo
{
  paulo* p;

  public:
	(interfaces to various methods)
	void setPaulo(paulo* newP);
	int usePaulo();
	int doSomething();
};

(end of 'pippo.h')------------------------

in file 'paulo.h'--------------------------

class pippo;	// Forward declaration. O.K.

class paulo
{
  pippo* pi;

  public:
	(interfaces to various methods)
	int setPippo(pippo* newPi);
	int usePippo();
	int doSomethingElse();
};

(end of 'paulo.h')-------------------------

Then in file 'pippo.cc' (or whatever file extension you use)

#include "pippo.h"
#include "paulo.h"  // This gives you access to paulo's methods

void pippo::setPaulo(paulo* newP)
{
  p = newP;
}

int pippo::usePaulo()
{
  if( p != NULL )
    return( p->doSomethingElse() );
  else
    return( -1 );
}

(end of 'pippo.cc')-------------------------

Same thing for paulo.cc

#include "paulo.h"
#include "pippo.h"  // This gives you access to pippo's methods

void paulo::setPippo(pippo* newP)
{
  pi = newP;
}

int paulo::usePippo()
{
  if( pi != NULL )
    return( pi->doSomething() );
  else
    return( -1 );
}

(end of 'paulo.cc')-------------------------

Hope this helps, Merry Christmas &c.

Mark Jackson

-- 

   !!!!!!!     ___________________________________
   +(.)(.)    (                                   )
   C   > )    |  HO, HO. MERRY CHRISTMAS, NETTERS |
    \ V / ----(___________________________________)
     ---

P.S. I tried email, but got 'Service Unavailable'....
Newsgroups: comp.lang.c++
From: ae2@cunixa.cc.columbia.edu (Amiran Eliashvili)
Subject: efficient memory management tools
Reply-To: ae2@cunixa.cc.columbia.edu (Amiran Eliashvili)
Organization: Columbia University
Date: Thu, 24 Dec 1992 21:32:18 GMT


Hi all:

	I was wondering if there are any memory management routines
that are recognized to be more efficient than standard ones, available
commercially or publicly.  Specifically, I am looking for malloc() and
free() routines or for equivalents.



Please reply to :
ae2@cunixa.cc.columbia.edu

thank
/amiran
From: maxtal@extro.ucc.su.OZ.AU (John MAX Skaller)
Subject: Re: Private base classes
Organization: MAXTAL P/L C/- University Computing Centre, Sydney
Date: Wed, 23 Dec 1992 14:58:41 GMT

In article <921221185102_76336.3114_EHJ5-2@CompuServe.COM> 76336.3114@CompuServe.COM (Kevin Dean) writes:
>From John Max Skeller, <1992Dec19.185132.13319@ucc.su.OZ.AU>:
>
>>In article <921216205429_76336.3114_EHJ34-2@CompuServe.COM>
>>76336.3114@CompuServe.COM (Kevin Dean) writes:
>>>
>>>I tried to do the following:
>>>
>>>class A {};
>>>class B : private A {};
>>>class C1 : public B, public A {};
>>>
>>>My compiler naturally warned me about A being both a direct and indirect
>>>base class of C1 and so refused to compile it.
>
>>     It was nice for your compiler to warn you.
>>     It was wrong for it to refuse your perfectly valid request.
>>     Your compiler is broken.
>
>>     Replicated *direct* bases are illegal, if only because there would
>>     be no way to disambiguate them.
>
>According to a note sent directly to me by Steve Clamage of TauMetric
>Corp and, I believe, the C++ language committee, the construct is indeed
>ambiguous because access rights are checked only after ambiguities are
>resolved; trying to do it the other way around would introduce other
>problems.  Given that access priviliges have no bearing on ambiguity
>resolution, what I was trying to do is illegal.

	I'm sorry I dont understand. Its not possible for
a class heirarchy to be ambiguous, only for an attempt to
reference something in it. In the above I see no ambiguous
references to anything. If there had been a function A::f,
and you tried to call it, there would be an ambiguity.

	So figure this one:

	class A ..... // hint hint
	class B : public A { ... }
	class C : public B, public A { ...}

It is possible to access BOTH A subobjects of C. How?

-- 
;----------------------------------------------------------------------
        JOHN (MAX) SKALLER,         maxtal@extro.ucc.su.oz.au
	Maxtal Pty Ltd, 6 MacKay St ASHFIELD, NSW 2131, AUSTRALIA
;--------------- SCIENTIFIC AND ENGINEERING SOFTWARE ------------------
Newsgroups: comp.lang.c++
From: pauljo@microsoft.com (Paul Johns)
Subject: Re: Do I need to worry about what the compiler will do?
Date: 29 Dec 92 01:48:33 GMT
Organization: Microsoft Corp.
Distribution: usa

In article <1992Dec24.155526.20892@umbc3.umbc.edu> reagle@umbc8.umbc.edu wrote:
> 
> 	This is the program I spoke of earlier concerning linked lists, and 
> constructors.  My question is since each node in the list is an object, is this
> inefficient?  Is each function of each object repeated in the object or 
> executable code?

No.  You get one copy of the member functions and any static member data
for the class, not one copy per object.

Read up on member functions and the this pointer to see how it works for
member functions.
Newsgroups: comp.lang.c++