Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #22347

Re: abbreviated generic syntax

NNTP-Posting-Date Mon, 18 Feb 2013 13:35:19 -0600
From "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org>
Newsgroups comp.lang.java.programmer
References <0h93i8pcopf17145fus96g7vams86hocat@4ax.com>
Subject Re: abbreviated generic syntax
Date Mon, 18 Feb 2013 19:33:52 -0000
X-Priority 3
X-MSMail-Priority Normal
X-Newsreader Microsoft Outlook Express 6.00.2900.5512
X-MimeOLE Produced By Microsoft MimeOLE V6.00.2900.5512
X-RFC2646 Format=Flowed; Original
Message-ID <QLydnaw4lfPqH7_MnZ2dnUVZ8oydnZ2d@bt.com> (permalink)
Lines 20
X-Usenet-Provider http://www.giganews.com
X-AuthenticatedUsername NoAuthUser
X-Trace sv3-Nb3eBb3/hOFU1xyo51J4v9aKvjoyKHaZ3L6xFL70XwNxWObD631Xg4suewiAkSHsd6rOEfF5dbORBPk!vsf2Tu5/ioQ6bpmtqCI8c0ZNG6g0kHJdWGRniH5azt8ZlHOOTSF/u+lE6N+sClHnW+CF2N7e7xo=
X-Complaints-To abuse@btinternet.com
X-DMCA-Complaints-To abuse@btinternet.com
X-Abuse-and-DMCA-Info Please be sure to forward a copy of ALL headers
X-Abuse-and-DMCA-Info Otherwise we will be unable to process your complaint properly
X-Postfilter 1.3.40
X-Original-Bytes 1668
Path csiph.com!usenet.pasdenom.info!news.stben.net!border3.nntp.ams.giganews.com!Xl.tags.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!local2.nntp.ams.giganews.com!nntp.bt.com!news.bt.com.POSTED!not-for-mail
Xref csiph.com comp.lang.java.programmer:22347

Show key headers only | View raw


Roedy Green wrote:
> In generics in Java 1.7 you can abbreviate
>
>   ArrayList<String> a = new ArrayList<String>( 100 );
>
> as
>
>   ArrayList<String> a = new ArrayList<>( 100 );
>
> Would any code have broken if you abbreviated like this instead:
>
>   ArrayList<String> a = new ArrayList( 100 );

It would greatly irritate those who think that the "new" generics stuff is of 
negative benefit, since now the compiler would be adding generics in /even when 
I hadn't asked for it/.

    -- chris 

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

abbreviated generic syntax Roedy Green <see_website@mindprod.com.invalid> - 2013-02-17 20:26 -0800
  Re: abbreviated generic syntax Daniel Pitts <newsgroup.nospam@virtualinfinity.net> - 2013-02-18 01:02 -0800
  Re: abbreviated generic syntax Barb Knox <see@sig.below> - 2013-02-18 22:41 +1300
    Re: abbreviated generic syntax Donkey Hottie <donkey@fredriksson.dy.fi> - 2013-02-18 12:58 +0200
    Re: abbreviated generic syntax Arne Vajhoej <arne@vajhoej.dk> - 2013-02-18 07:20 -0500
      Re: abbreviated generic syntax Arne Vajhoej <arne@vajhoej.dk> - 2013-02-18 07:27 -0500
  Re: abbreviated generic syntax Arne Vajhoej <arne@vajhoej.dk> - 2013-02-18 07:23 -0500
  Re: abbreviated generic syntax "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org> - 2013-02-18 19:33 +0000
  Re: abbreviated generic syntax BGB <cr88192@hotmail.com> - 2013-02-18 13:46 -0600
  Re: abbreviated generic syntax Lew <lewbloch@gmail.com> - 2013-02-18 12:29 -0800
    Re: abbreviated generic syntax Robert Klemme <shortcutter@googlemail.com> - 2013-02-18 22:49 +0100
      Re: abbreviated generic syntax Lew <lewbloch@gmail.com> - 2013-02-18 13:51 -0800
    Re: abbreviated generic syntax Roedy Green <see_website@mindprod.com.invalid> - 2013-02-18 15:35 -0800
      Re: abbreviated generic syntax lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-02-19 08:56 +0000
        Re: abbreviated generic syntax lipska the kat <"nospam at neversurrender dot co dot uk"> - 2013-02-19 12:30 +0000
      Re: abbreviated generic syntax Andreas Leitgeb <avl@gamma.logic.tuwien.ac.at> - 2013-02-19 16:21 +0000
      Re: abbreviated generic syntax Joshua Cranmer 🐧 <Pidgeot18@verizon.invalid> - 2013-02-19 11:38 -0600
      Re: abbreviated generic syntax Arne Vajhoej <arne@vajhoej.dk> - 2013-02-19 12:45 -0500
        Re: abbreviated generic syntax BGB <cr88192@hotmail.com> - 2013-02-19 15:20 -0600

csiph-web