Skip to content

Commit 1ddd0d7

Browse files
committed
replace ndarray by c-style array
for device support with clang and CUDA 11
1 parent 9da6332 commit 1ddd0d7

File tree

1 file changed

+8
-9
lines changed

1 file changed

+8
-9
lines changed

include/deal.II/base/symmetric_tensor.h

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1986,23 +1986,22 @@ namespace internal
19861986
}
19871987
case 2:
19881988
{
1989-
constexpr dealii::ndarray<unsigned int, 2, 2> table = {
1990-
{{{0, 2}}, {{2, 1}}}};
1989+
constexpr unsigned int table[2][2] = {{0, 2}, {2, 1}};
19911990
return table[indices[0]][indices[1]];
19921991
}
19931992
case 3:
19941993
{
1995-
constexpr dealii::ndarray<unsigned int, 3, 3> table = {
1996-
{{{0, 3, 4}}, {{3, 1, 5}}, {{4, 5, 2}}}};
1994+
constexpr unsigned int table[3][3] = {{0, 3, 4},
1995+
{3, 1, 5},
1996+
{4, 5, 2}};
19971997
return table[indices[0]][indices[1]];
19981998
}
19991999
case 4:
20002000
{
2001-
constexpr dealii::ndarray<unsigned int, 4, 4> table = {
2002-
{{{0, 4, 5, 6}},
2003-
{{4, 1, 7, 8}},
2004-
{{5, 7, 2, 9}},
2005-
{{6, 8, 9, 3}}}};
2001+
constexpr unsigned int table[4][4] = {{0, 4, 5, 6},
2002+
{4, 1, 7, 8},
2003+
{5, 7, 2, 9},
2004+
{6, 8, 9, 3}};
20062005
return table[indices[0]][indices[1]];
20072006
}
20082007
default:

0 commit comments

Comments
 (0)