From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9cccf6ef6149fdaa X-Google-Attributes: gid103376,public From: Hyman Rosen Subject: Re: Ada Date: 2000/01/04 Message-ID: #1/1 X-Deja-AN: 568174735 Sender: hymie@calumny.jyacc.com References: <38620350.48F8FC08@gecm.com> <83tohh$q2s$1@nnrp1.deja.com> <83u8l0$5i5$1@nnrp1.deja.com> <84rd2f$snm$1@nntp3.atl.mindspring.net> <874scu18cs.fsf@deneb.cygnus.argh.org> X-Complaints-To: abuse@panix.com X-Trace: news.panix.com 946997610 4407 209.49.126.226 (4 Jan 2000 14:53:30 GMT) Organization: PANIX Public Access Internet and UNIX, NYC NNTP-Posting-Date: 4 Jan 2000 14:53:30 GMT Newsgroups: comp.lang.ada Date: 2000-01-04T14:53:30+00:00 List-Id: Florian Weimer writes: > You won't get reasonable error messages. For example, try instantiating > a STL container with a reference type; most compilers will give you > several kilobytes of error messages. The situation gets worse if you > nest templates more deeply. This is a quality-of-implementation issue. I think vendors are concentrating first on compiling correct code. One hopes that in the future, error messages will get better. > Writing reusable templates in C++ is hard, because you have to be very > careful not to use operations on the parametric types which aren't > available in general. These restrictions are not enforced by the > compiler unless you provide suitable instantiations. "If the type will fit, you must acquit" :-) The C++ template model allows legal instantiations to compile, without specifying restrictions on the types in advance, only through the operations performed on the objects of the type. This requires attention in writing the template if you want to minimize the number of things required of the type, but that's fine.