From -5710358836686229287
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f78e5,4bcb385f3c23e7d9,start
X-Google-Attributes: gidf78e5,public
From: James Kanze <james-albert.kanze@vx.cit.alcatel.fr>
Subject: Re: Seg fault with cout and cerr streams on SGI
Date: 1997/04/02
Message-ID: <rf5d8sdx210.fsf@vx.cit.alcatel.fr>#1/1
X-Deja-AN: 230179514
References: <5hjl1e$oak@netlab.cs.rpi.edu> <5hoouj$9ld@netlab.cs.rpi.edu>
X-Original-Date: 02 Apr 1997 10:27:39 +0200
Organization: -
X-Auth: PGPMoose V1.1 PGP comp.std.c++
Newsgroups: comp.std.c++
Originator: austern@isolde.mti.sgi.com


dacut@henry.ece.cmu.edu (David A. Cuthbert) writes:

|>  #include <malloc>
|>  #include <new>
|>  #include <iostream>
|>  
|>  void *  operator new(size_t bytesReq) {
|>  	cerr << "Requesting " << bytesReq << " bytes" << endl;
|>  	return malloc(bytesReq);
|>  }

Generally speaking, I suspect that the above function will result in an
infinite recursion in most implementations, and I believe that it should
be illegal.  (No point in making things overly difficult for the
implementor without reason.)

Still, I'm curious to know what passage in the current draft makes it
illegal.  I'm not aware of one.

-- 
James Kanze      home:     kanze@gabi-soft.fr        +33 (0)1 39 55 85 62
                 office:   kanze@vx.cit.alcatel.fr   +33 (0)1 69 63 14 54
GABI Software, Sarl., 22 rue Jacques-Lemercier, F-78000 Versailles France
	    -- Conseils en informatique industrielle --
---
[ comp.std.c++ is moderated.  To submit articles: Try just posting with your 
                newsreader.  If that fails, use mailto:std-c++@ncar.ucar.edu
  comp.std.c++ FAQ: http://reality.sgi.com/austern/std-c++/faq.html
  Moderation policy: http://reality.sgi.com/austern/std-c++/policy.html
  Comments? mailto:std-c++-request@ncar.ucar.edu 
]



