couchdb-khash.git
15 months agoMerge branch 'rand-compat' master 1.0.1
Nick Vatamaniuc [Thu, 5 Oct 2017 17:15:00 +0000 (13:15 -0400)] 
Merge branch 'rand-compat'

Fixes #9

15 months agoHandle deprecated random module 9/head
Nick Vatamaniuc [Tue, 3 Oct 2017 06:03:19 +0000 (02:03 -0400)] 
Handle deprecated random module

Use a compile time check for platform versions, then a macro conditional in a
separate rand module.

Removed redunant beam file compile rule from Makefile as it prevented erl_opts
rebar options form taking effect.

15 months agoFix iterator expiry test 8/head
Nick Vatamaniuc [Mon, 2 Oct 2017 20:37:56 +0000 (16:37 -0400)] 
Fix iterator expiry test

This test started failing with Erlang 20.0 release. The reason is that opaaque
NIF resources stopped being identifed as empty binaries in Erlang so previously
it matched but once refs were used it stopped matching.

Fixes #855

15 months agoMerge branch 'replace-deprecated-random-module'
Nick Vatamaniuc [Mon, 2 Oct 2017 19:17:43 +0000 (15:17 -0400)] 
Merge branch 'replace-deprecated-random-module'

Fixes #7

15 months agoReplace deprecated random module 7/head
Nick Vatamaniuc [Mon, 2 Oct 2017 18:51:32 +0000 (14:51 -0400)] 
Replace deprecated random module

Replaced with crypto:rand_uniform functions.

Also updated .travis.yml to the default set of Erlang releases.

3 years agoRemove flaky eunit test. 6/head 1.0.0
Nick Vatamaniuc [Mon, 12 Oct 2015 16:49:25 +0000 (12:49 -0400)] 
Remove flaky eunit test.

This test is a race benchmark to prove khash is faster than dict. It was used in early stages of development. In the context of eunit tests it has the potential to fail occasionally and make test suite results unreliable.

 COUCHDB-2848

3 years agoIncrease timeout limit for randomized and comparison tests 5/head
Alexander Shorin [Fri, 24 Jul 2015 02:38:11 +0000 (05:38 +0300)] 
Increase timeout limit for randomized and comparison tests

3 years agoIntegrate with Travis CI
Alexander Shorin [Fri, 24 Jul 2015 02:31:52 +0000 (05:31 +0300)] 
Integrate with Travis CI

3 years agoUpdate Makefile
Alexander Shorin [Fri, 24 Jul 2015 02:31:45 +0000 (05:31 +0300)] 
Update Makefile

- Sort make commands
- Add make help and descriptions for the available commands
- Remove related path to rebar

3 years agoSupport Windows build
Joan Touzet [Thu, 16 Jul 2015 23:03:57 +0000 (19:03 -0400)] 
Support Windows build

3 years agofix previous merge
Robert Newson [Thu, 16 Jul 2015 23:09:04 +0000 (00:09 +0100)] 
fix previous merge

3 years agoRemove the use of make_hash2 3/head
Paul J. Davis [Tue, 14 Jul 2015 06:08:26 +0000 (01:08 -0500)] 
Remove the use of make_hash2

We were being rather naughty relying on the ability to resolve symbols
in the executable that loads the NIF. Apparently Windows has a much
different NIF loading system which prevents this from working. Given
that the patch for exposing enif_phash was never merged we're solving
the issue by removing the need from hashing terms in the NIF.

This new approach simply hashes the term in Erlang and passes the
calculated value in the NIF call. We then just store the calculated
value along with the key and value as before.

COUCHDB-2750

3 years agoMigrate the tests from etap to eunit
Eric Avdey [Mon, 4 May 2015 18:38:27 +0000 (15:38 -0300)] 
Migrate the tests from etap to eunit

All the etap tests converted to eunit.

COUCHDB-2590

3 years agoFix "dereferencing type-punned pointer will break strict-aliasing" warn 1/head
Alexander Shorin [Wed, 15 Jul 2015 21:09:08 +0000 (00:09 +0300)] 
Fix "dereferencing type-punned pointer will break strict-aliasing" warn

COUCHDB-2588

4 years agoFix resource destructors windsor-merge
Paul J. Davis [Fri, 16 Aug 2013 16:14:44 +0000 (11:14 -0500)] 
Fix resource destructors

Apparently the resource name is quite important. The old code was
attempting to free all hashes with the iterator destructor which also
had a bug that masked the underlying issue. This fixes the wrong
destructor issue as well as the iterator destructor bug.

4 years agoFix tests on R14B01
Paul J. Davis [Fri, 16 Aug 2013 16:13:58 +0000 (11:13 -0500)] 
Fix tests on R14B01

4 years agoMinor test code cleanup
Paul J. Davis [Sat, 11 May 2013 19:50:46 +0000 (14:50 -0500)] 
Minor test code cleanup

4 years agoAdd support for iteration
Paul J. Davis [Sat, 11 May 2013 19:50:05 +0000 (14:50 -0500)] 
Add support for iteration

A basic iterator with accompanying fold/3 support.

4 years agoRemove the ability to share khash's
Paul J. Davis [Sat, 11 May 2013 19:49:02 +0000 (14:49 -0500)] 
Remove the ability to share khash's

I don't need this right now and it'll interfere with iterators.

4 years agoInitial implementation
Paul J. Davis [Sat, 11 May 2013 06:12:10 +0000 (01:12 -0500)] 
Initial implementation

This is a quick wrapper around the kazlib hash structure. Its fairly
straight forward.

4 years agoInitial import
Paul J. Davis [Sat, 11 May 2013 03:57:20 +0000 (22:57 -0500)] 
Initial import