test/tools/javac/ArraysInIntersections.java

Wed, 30 Oct 2013 18:09:49 +0000

author
vromero
date
Wed, 30 Oct 2013 18:09:49 +0000
changeset 2173
537fa895fd74
parent 2079
de1c5dbe6c28
permissions
-rw-r--r--

8027327: jar files related to test test/tools/javac/ExtDirs/ExtDirTest.java should be removed from the repo
Reviewed-by: ksrini

emc@2079 1 /*
emc@2079 2 * Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
emc@2079 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
emc@2079 4 *
emc@2079 5 * This code is free software; you can redistribute it and/or modify it
emc@2079 6 * under the terms of the GNU General Public License version 2 only, as
emc@2079 7 * published by the Free Software Foundation.
emc@2079 8 *
emc@2079 9 * This code is distributed in the hope that it will be useful, but WITHOUT
emc@2079 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
emc@2079 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
emc@2079 12 * version 2 for more details (a copy is included in the LICENSE file that
emc@2079 13 * accompanied this code).
emc@2079 14 *
emc@2079 15 * You should have received a copy of the GNU General Public License version
emc@2079 16 * 2 along with this work; if not, write to the Free Software Foundation,
emc@2079 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
emc@2079 18 *
emc@2079 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
emc@2079 20 * or visit www.oracle.com if you need additional information or have any
emc@2079 21 * questions.
emc@2079 22 */
emc@2079 23
emc@2079 24 /*
emc@2079 25 * @test
emc@2079 26 * @bug 8021339
emc@2079 27 * @summary Allow arrays in intersection types
emc@2079 28 * @compile ArraysInIntersections.java
emc@2079 29 */
emc@2079 30
emc@2079 31 import java.io.Serializable;
emc@2079 32
emc@2079 33 public class ArraysInIntersections<T extends Serializable & Integer[]> {
emc@2079 34
emc@2079 35 public <S extends Serializable & Integer[]> Object m() {
emc@2079 36 return (Serializable & Integer[]) new Integer[1];
emc@2079 37 }
emc@2079 38
emc@2079 39 }

mercurial