blob: 9e1becbdbf64cd642ead63990bed64776134dd5e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
using System;
using System.Collections.Generic;
using System.Numerics;
// GitHub18043: ensure dead box optimizations treat Vector<float> as a struct type.
class X
{
public static int VT()
{
Vector<float> f = new Vector<float>(4);
Vector<float>[] a = new Vector<float>[10];
a[5] = f;
return Array.IndexOf(a, f);
}
public static int Main()
{
int r1 = VT();
return (r1 == 5 ? 100 : 0);
}
}
|