Disabled external gits
This commit is contained in:
27
cs440-acg/ext/openexr/IlmBase/HalfTest/testSize.cpp
Normal file
27
cs440-acg/ext/openexr/IlmBase/HalfTest/testSize.cpp
Normal file
@@ -0,0 +1,27 @@
|
||||
#include <testSize.h>
|
||||
#include "half.h"
|
||||
#include <iostream>
|
||||
#include <assert.h>
|
||||
#include <stddef.h>
|
||||
|
||||
|
||||
using namespace std;
|
||||
|
||||
|
||||
void
|
||||
testSize ()
|
||||
{
|
||||
cout << "size and alignment\n";
|
||||
|
||||
half h[2];
|
||||
|
||||
int size = sizeof (half);
|
||||
ptrdiff_t algn = (char *)&h[1] - (char *)&h[0];
|
||||
|
||||
cout << "sizeof (half) = " << size << endl;
|
||||
cout << "alignof (half) = " << (int) algn << endl;
|
||||
|
||||
assert (size == 2 && algn == 2);
|
||||
|
||||
cout << "ok\n\n" << flush;
|
||||
}
|
Reference in New Issue
Block a user