home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!taumet!steve
- From: steve@taumet.com (Steve Clamage)
- Subject: Re: defining cast operators outside classes
- Message-ID: <1992Sep9.161513.27698@taumet.com>
- Organization: TauMetric Corporation
- References: <TMB.92Sep7162324@arolla.idiap.ch> <1992Sep8.173613.25113@taumet.com> <TMB.92Sep8215104@arolla.idiap.ch>
- Date: Wed, 9 Sep 1992 16:15:13 GMT
- Lines: 31
-
- tmb@arolla.idiap.ch (Thomas M. Breuel) writes:
-
- |In article <1992Sep8.173613.25113@taumet.com> steve@taumet.com (Steve Clamage) writes:
-
- | tmb@arolla.idiap.ch (Thomas M. Breuel) writes:
-
- | >Apparently, it is impossible to define a conversion operator for a
- | >class without making the conversion operator a member function.
-
- | In the case of some operators you run the risk of having legal code
- | with different meanings depending on whether the operator declaration
- | is visible.
-
- |Why is the C++ committee suddenly so concerned with my well-being?
- |Those people who feel that such a feature is dangerous simply don't
- |define conversion operators outside their classes.
-
- This is not sudden, and not the action of the C++ committee. The
- rule is in the ARM, and predates the formation of the committee.
- I was presenting a rationale for the rule, with which you are free
- to disagree.
-
- You are also free to submit a proposal to the C++ committee to change
- the language in this regard. Guidelines on how to create and submit
- such a proposal have been published in various places. You could also
- join the committee and argue your viewpoints more directly.
-
- --
-
- Steve Clamage, TauMetric Corp, steve@taumet.com
- Vice Chair, ANSI C++ Committee, X3J16
-