diff options
Diffstat (limited to 'tests/langbench/hash.l')
-rw-r--r-- | tests/langbench/hash.l | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/langbench/hash.l b/tests/langbench/hash.l new file mode 100644 index 0000000..ab10f2e --- /dev/null +++ b/tests/langbench/hash.l @@ -0,0 +1,17 @@ +void +main(int ac, string av[]) +{ + int i; + string buf; + hash h; + FILE f; + + + for (i = 1; i < ac; ++i) { + f = open(av[i], "rb"); + while (gets(f, &buf) >= 0) { + h{buf} = 1; + } + close(f); + } +} |