2019-06-04 00:14:04 -04:00
|
|
|
package ast
|
|
|
|
|
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
)
|
|
|
|
|
|
|
|
func TestShuffleVectorExpr(t *testing.T) {
|
|
|
|
nodes := map[string]testNode{
|
2019-06-11 12:38:22 -04:00
|
|
|
`0x7fdef0862430 <line:120:1, col:16>`: testNode{&ShuffleVectorExpr{
|
|
|
|
Addr: 0x7fdef0862430,
|
|
|
|
Pos: NewPositionFromString("line:120:1, col:16"),
|
|
|
|
Type: "",
|
|
|
|
Type2: "",
|
|
|
|
ChildNodes: []Node{},
|
2019-06-04 00:14:04 -04:00
|
|
|
},
|
2019-06-11 12:38:22 -04:00
|
|
|
0x7fdef0862430,
|
|
|
|
NewPositionFromString("line:120:1, col:16"),
|
|
|
|
[]Node{},
|
2019-06-04 00:14:04 -04:00
|
|
|
},
|
2019-06-11 12:38:22 -04:00
|
|
|
`0x113368318 <line:1354:20, line:1355:70> '__v4sf':'__attribute__((__vector_size__(4 * sizeof(float)))) float'`: testNode{&ShuffleVectorExpr{
|
|
|
|
Addr: 0x113368318,
|
|
|
|
Pos: NewPositionFromString("line:1354:20, line:1355:70"),
|
|
|
|
Type: `__v4sf`,
|
|
|
|
Type2: `:'__attribute__((__vector_size__(4 * sizeof(float)))) float'`,
|
|
|
|
ChildNodes: []Node{},
|
2019-06-04 00:14:04 -04:00
|
|
|
},
|
2019-06-11 12:38:22 -04:00
|
|
|
0x113368318,
|
|
|
|
NewPositionFromString("line:1354:20, line:1355:70"),
|
|
|
|
[]Node{},
|
2019-06-04 00:14:04 -04:00
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
runNodeTests(t, nodes)
|
|
|
|
}
|