diff options
author | Flaviu Tamas <tamasflaviu@gmail.com> | 2015-05-26 19:32:50 -0400 |
---|---|---|
committer | Flaviu Tamas <tamasflaviu@gmail.com> | 2015-06-07 13:12:18 -0400 |
commit | 90ed34db72e8ea8f70d1e86dd2335efe48532fa8 (patch) | |
tree | 9d9e46c0ddbb87f562981f072220bd36a7f199cb /lib/pure/rationals.nim | |
parent | 075a5e844069979f1fc3782839e9e2cc62c61ad5 (diff) | |
parent | bbb1bdb4a939aa43ed981acc2f96bce918be7d21 (diff) | |
download | Nim-90ed34db72e8ea8f70d1e86dd2335efe48532fa8.tar.gz |
Merge branch 'devel' of https://github.com/Araq/Nim into add-nre
* 'devel' of https://github.com/Araq/Nim: Fix #964, fix #1384 Don't inspect typedescs
Diffstat (limited to 'lib/pure/rationals.nim')
-rw-r--r-- | lib/pure/rationals.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/pure/rationals.nim b/lib/pure/rationals.nim index 3b68a2381..8e1dbe464 100644 --- a/lib/pure/rationals.nim +++ b/lib/pure/rationals.nim @@ -206,13 +206,13 @@ proc abs*[T](x: Rational[T]): Rational[T] = result.num = abs x.num result.den = abs x.den -proc hash*[T](x: Rational[T]): THash = +proc hash*[T](x: Rational[T]): Hash = ## Computes hash for rational `x` # reduce first so that hash(x) == hash(y) for x == y var copy = x reduce(copy) - var h: THash = 0 + var h: Hash = 0 h = h !& hash(copy.num) h = h !& hash(copy.den) result = !$h |