blob: 0a838e3e51ea111c5dc056c2e8c0eb197ee61052 [file] [log] [blame]
/*
* Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
* for details. All rights reserved. Use of this source code is governed by a
* BSD-style license that can be found in the LICENSE file.
*/
/**
* @assertion Int32x4 greaterThan(Float32x4 other)
* Relational greater than.
* @description Checks that the returned [Int32x4]
* contains correct values.
* @author msyabro
*/
import "dart:typed_data";
import "../../../Utils/expect.dart";
check(op1, op2, expected) {
var res = op1.greaterThan(op2);
Expect.equals(expected.x, res.x);
Expect.equals(expected.y, res.y);
Expect.equals(expected.z, res.z);
Expect.equals(expected.w, res.w);
}
main() {
check(new Float32x4(.0, .0, .0, .0), new Float32x4(.0, .0, .0, .0), new Int32x4.bool(false, false, false, false));
check(new Float32x4(.0, .0, .0, .0), new Float32x4(-1.0, -1.0, -.02, -1.32), new Int32x4.bool(true, true, true, true));
check(new Float32x4(1.0, 10.0, 1e-2, 0.23e40), new Float32x4(1.0, 2.0, 1e-3, .04e-2), new Int32x4.bool(false, true, true, true));
}