Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
bigerl authored Mar 22, 2021
1 parent 6ce2a6e commit 2f4c37a
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ add
FetchContent_Declare(
dice-hash
GIT_REPOSITORY https://github.com/dice-group/dice-hash.git
GIT_TAG 0.1.0
GIT_TAG 0.2.0
GIT_SHALLOW TRUE)
FetchContent_MakeAvailable(dice-hash)
Expand All @@ -34,10 +34,12 @@ target_link_libraries(your_target
### conan
To use it with [conan](https://conan.io/) you need to add the repository:
```shell
conan remote add dice-group https://api.bintray.com/conan/dice-group/tentris
conan remote add dice-group https://conan.dice-research.org/artifactory/api/conan/tentris
```

To use it add `dice-hash/0.1.0@dice-group/stable` to the `[requires]` section of your conan file.
To use it add `dice-hash/0.2.0@dice-group/stable` to the `[requires]` section of your conan file.

To activate march=native, you can additionally add `dice-hash:march=native` to the `[options]` section.

## build and run tests

Expand All @@ -53,6 +55,8 @@ make -j tests_dice_hash
./test/tests_dice_hash
```

`-march=native` is activated by the additional CMake option: `-DDICE_HASH_MARCH=native`

## usage
The hash is already defined for a lot of common types. In that case you can use the `DiceHash` just like `std::hash`.
```c++
Expand Down Expand Up @@ -95,4 +99,4 @@ Your container __needs__ to have `begin`, `end` and `size` functions.
One simple example can be found [here](examples/customContainer.cpp).
If you want to use `DiceHash` in a different structure (like `std::unordered_map`), you will need to set `DiceHash` as the correct template parameter.
[This](examples/usageForUnorderedSet.cpp) is one example.
[This](examples/usageForUnorderedSet.cpp) is one example.

0 comments on commit 2f4c37a

Please sign in to comment.