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.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,13c7ec19f3c43155,start X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!postnews.google.com!t12g2000prg.googlegroups.com!not-for-mail From: "jhc0033@gmail.com" Newsgroups: comp.lang.ada Subject: speed of generic code in Ada (vs Java) Date: Fri, 16 May 2008 10:31:10 -0700 (PDT) Organization: http://groups.google.com Message-ID: <9e9bdae7-5e91-4e0c-b783-1ed72311a733@t12g2000prg.googlegroups.com> NNTP-Posting-Host: 75.18.114.21 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: posting.google.com 1210959070 27308 127.0.0.1 (16 May 2008 17:31:10 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 16 May 2008 17:31:10 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: t12g2000prg.googlegroups.com; posting-host=75.18.114.21; posting-account=ZDEUcwoAAAAfEl68GET6fODebgE-CIe2 User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.14) Gecko/20080404 Firefox/2.0.0.14,gzip(gfe),gzip(gfe) Xref: g2news1.google.com comp.lang.ada:108 Date: 2008-05-16T10:31:10-07:00 List-Id: Java only allows 'objects' as generics parameters. So, if you define a generic class and use 'Integer' as a parameter, your code will be slow because of the boxing - up to 5x compared to non-generic Int (see the recent discussion in comp.lang.java.programmer - the 'numerics' thread). Is the situation similar with generics in Ada, GNAT, specifically?