src/oneShot/test/test.c 1.35
1.35 2009/02/24 03:09:04 kent
Testing floating point binary representation.
Index: src/oneShot/test/test.c
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/oneShot/test/test.c,v
retrieving revision 1.34
retrieving revision 1.35
diff -b -B -U 1000000 -r1.34 -r1.35
--- src/oneShot/test/test.c 10 Feb 2009 22:10:19 -0000 1.34
+++ src/oneShot/test/test.c 24 Feb 2009 03:09:04 -0000 1.35
@@ -1,33 +1,35 @@
/* test - Test something. */
#include "common.h"
#include "linefile.h"
#include "hash.h"
#include "options.h"
#include "dnautil.h"
#include "xp.h"
void usage()
/* Explain usage and exit. */
{
errAbort(
"test - Test something\n"
"usage:\n"
" test a \n"
"options:\n"
);
}
void test(char *word)
{
-printf("%d\n", word[0]);
+FILE *f = mustOpen(word, "wb");
+float x = 1.23456;
+mustWrite(f, &x, sizeof(x));
}
int main(int argc, char *argv[], char *env[])
/* Process command line. */
{
if (argc != 2)
usage();
test(argv[1]);
return 0;
}