From -5782199045856883448
X-Google-Thread: f78e5,edf2eb1d3f0f9755
X-Google-Attributes: gidf78e5,public
X-Google-Language: ENGLISH,ASCII-7-bit
Path: g2news1.google.com!news2.google.com!news.maxwell.syr.edu!border1.nntp.dca.giganews.com!nntp.giganews.com!peer01.cox.net!cox.net!peer-uk.news.demon.net!kibo.news.demon.net!news.demon.co.uk!demon!stump.algebra.com!devnull
From: someone@nowhere.com (Roshan Naik)
Newsgroups: comp.std.c++
Subject: Re: Multithreaded programming: is the C++ standardization 
 committeelistening?
Date: Sat, 21 Aug 2004 16:45:38 GMT
Organization: Hewlett-Packard
Lines: 46
Sender: mail2news@demon.net
Approved: fjh@cs.mu.oz.au (Fergus Henderson , moderator of comp.std.c++)
Message-ID: <41255327.8D3AEF5E@nowhere.com>
References: <2ofbepFa2tpoU1@uni-berlin.de> <5b15f8fd.0408180300.6413ef48@posting.google.com> <4124340A.3050809@ieee.org>
NNTP-Posting-Host: news.news.demon.net
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Trace: news.demon.co.uk 1093106750 27581 158.152.254.254 (21 Aug 2004 16:45:50 GMT)
X-Complaints-To: abuse@demon.net
NNTP-Posting-Date: Sat, 21 Aug 2004 16:45:50 +0000 (UTC)
X-Robomod: STUMP, ichudov@algebra.com (Igor Chudov)
X-Spam-Checker-Version: SpamAssassin 2.64-mulga_r1 (2004-01-11) on 
	mulga.cs.mu.OZ.AU
X-Spam-Status: No, hits=-4.9 required=5.0 tests=BAYES_00 autolearn=ham 
	version=2.64-mulga_r1
X-Accept-Language: en
X-Path: comp-std-cpp-robomod!not-for-mail
X-Received: (from fjh@localhost)
	by mulga.cs.mu.OZ.AU (8.12.10+Sun/8.12.9/Submit) id i7LGjcvR000520;
	Sun, 22 Aug 2004 02:45:38 +1000 (EST)
X-NNTP-Posting-Date: Thu, 19 Aug 2004 18:26:00 PDT
X-Delivered-To: std-c++@ucar.edu
X-Authentication-Warning: mulga.cs.mu.OZ.AU: fjh set sender to devnull@stump.algebra.com using -f
X-Newsgroups: comp.std.c++
Xref: g2news1.google.com comp.std.c++:1954


Jim Hyslop wrote:

> Dietmar Kuehl wrote:
> > The standardization committee is well aware of the existance of threads
> > and I doubt that it will reject a reasonable proposal adding threads to
> > C++ (although such a proposal probably will have to address how thread
> > support is to be implemented on systems not supporting threads).
>
> Implementing the support is quite trivial, actually. A system that does
> not support threads generates exactly the code that is required:
> nothing. It should be easy enough to recognize the MT features and just
> ignore them. I'd prefer ignoring MT features over generating an error,
> because with an error you don't have portable code: you have to wrap
> your code in ugly #ifdefs.
>

There are two parts to that ignoring versus compile time errors.
First the core language features for MT , and second Standard Library
portions.

Lets say the threads and locks related abstractions go into the header
<thread>
When users tries to #include <thread> in order to instantate threads and fire
off multiple
threads on a non-MT system, the compiler should preferrable to indicate a
clear
*compiler error* at compile time rather than at run time. This should be a
trivial to do
using compile time asserts.... on just not shipping a <thread> on that system
:-)

But in the case of core language features (like if they decided on new
keywords or
type modifiers or things of that nature) those obviously should be ignored at
compile time
instead of issuing errors.

-Roshan

---
[ comp.std.c++ is moderated.  To submit articles, try just posting with ]
[ your news-reader.  If that fails, use mailto:std-c++@ncar.ucar.edu    ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.jamesd.demon.co.uk/csc/faq.html                       ]



