Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Fix variable 'Bytes' exported from 'case' #1

Merged
merged 1 commit into from

2 participants

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jun 24, 2012
  1. @voluntas
This page is out of date. Refresh to see the latest.
Showing with 6 additions and 6 deletions.
  1. +6 −6 src/binpp.erl
View
12 src/binpp.erl
@@ -77,12 +77,12 @@ cmprint(Bin1, Bin2) when is_binary(Bin1) orelse is_bitstring(Bin1),
-spec from_str(string(), hex) -> binary().
from_str(Str, hex) when is_list(Str) ->
- case lists:member($ , Str) of
- true ->
- Bytes = string:tokens(Str, " ");
- false when length(Str) rem 2 =:= 0 ->
- Bytes = buckets(2, Str)
- end,
+ Bytes = case lists:member($ , Str) of
+ true ->
+ string:tokens(Str, " ");
+ false when length(Str) rem 2 =:= 0 ->
+ buckets(2, Str)
+ end,
list_to_binary([ list_to_integer(B,16) || B <- Bytes]).
-spec from_str(string()) -> binary().
Something went wrong with that request. Please try again.