andrewjstone/rafter — pull request #29 by bryanhunter (2014-05-19 04:45:32+00:00)
Title: Fixed warning that prevented build on R17

Fixed 'type dict/0 is deprecated and will be removed in OTP 18.0' warnings that prevented build on R17.

Previously....
```
$ git clone git@github.com:andrewjstone/rafter.git
$ cd rafter
$ make deps
$ make
...
==> rafter (compile)
Compiled src/rafter_backend.erl
Compiled src/rafter_app.erl
compile: warnings being treated as errors
include/rafter_consensus_fsm.hrl:22: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
include/rafter_consensus_fsm.hrl:27: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
include/rafter_consensus_fsm.hrl:35: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
make: *** [rafter] Error 1
```

...fixed these by replacing dict() with dict:dict() in specs

```
$ make
...
==> rafter (compile)
Compiled src/rafter_backend_echo.erl
Compiled src/rafter.erl
Compiled src/rafter_backend_ets.erl
Compiled src/rafter_consensus_sup.erl
compile: warnings being treated as errors
src/rafter_config.erl:13: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_config.erl:37: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_config.erl:115: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_config.erl:128: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
make: *** [rafter] Error 1
```

...fixed these by replacing dict() with dict:dict() in specs

````
$ make
...
==> rafter (compile)
Compiled src/rafter_config.erl
Compiled src/rafter_log.erl
compile: warnings being treated as errors
src/rafter_consensus_fsm.erl:475: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_consensus_fsm.erl:475: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_consensus_fsm.erl:487: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_consensus_fsm.erl:487: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_consensus_fsm.erl:493: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
src/rafter_consensus_fsm.erl:493: type dict/0 is deprecated and will be removed in OTP 18.0; use use dict:dict/0 or preferably dict:dict/2
make: *** [rafter] Error 1
```
...fixed these by replacing dict() with dict:dict() in specs

$ make
...
All good. :)