blob: 2f8b41504e03695f9bcd7b5e1dee198600cd7659 [file] [log] [blame]
Aart Bikf417ff42016-04-25 12:51:37 -07001#
2# Copyright (C) 2016 The Android Open Source Project
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15
16.class public LMerge;
17.super Ljava/lang/Object;
18
19# Method that selects between x = new Integer[] or new AnError[],
20# Reference type propagation should correctly see error in component type.
21.method public static select(Z)Ljava/lang/Object;
22 .registers 2
23 const/16 v0, 10
24 if-eqz v1, :Skip
25 new-array v0, v0, [LAnError;
26 goto :Done
27:Skip
28 new-array v0, v0, [Ljava/lang/Integer;
29:Done
30 return-object v0
31.end method