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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,262b74f44c7f873e X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news2.google.com!news4.google.com!news.glorb.com!newsfeed-east.nntpserver.com!nntpserver.com!statler.nntpserver.com!newsfeed.arcor.de!news.arcor.de!not-for-mail From: "Dmitry A. Kazakov" Subject: Re: prohibit certain generic instantiations in Ada 2005 Newsgroups: comp.lang.ada User-Agent: 40tude_Dialog/2.0.14.1 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Reply-To: mailbox@dmitry-kazakov.de Organization: cbb software GmbH References: <1139508110.410006.28260@g14g2000cwa.googlegroups.com> <1139515341.782860.197930@f14g2000cwb.googlegroups.com> <1139581110.636535.107910@g44g2000cwa.googlegroups.com> <1139598205.17535.46.camel@sonnenregen> Date: Sat, 11 Feb 2006 11:45:32 +0100 Message-ID: <1573u53mucvzs$.1ffxvsbwlfggm$.dlg@40tude.net> NNTP-Posting-Date: 11 Feb 2006 11:45:22 MET NNTP-Posting-Host: 79f889a0.newsread4.arcor-online.net X-Trace: DXC=a`Dn32h_S?VXNWN: On Fri, 10 Feb 2006 20:03:25 +0100, Georg Bauhaus wrote: > On Fri, 2006-02-10 at 19:25 +0100, Dmitry A. Kazakov wrote: > >> So, >> basically, C++ is unable to check anything specific about the type of >> template a parameter. > > Don't you think that while template doesn't > require T to conform to some type, T's operations can > still be named in the template definition? Like with > the Can_Copy example that Stroustrup explains? Things from the definition are checked upon instantiation = too late. Talking about compile-time checks, we should separate compilation of templates and their instantiations. In my view, anything checked outside the formal part does not count, because it is *other* compile-time. [ Let you use a code management system and a template library is under that system. Then each time you ship a new version of the library, all the projects dependant on it should get a new version as well. Now, because templates aren't properly checked, you can't much rely on them until you try. In the end, you have an immense overhead in the developing cycle.] -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de