summaryrefslogtreecommitdiff
path: root/src/lib/rand.go
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2008-10-07 12:31:31 -0700
committerRuss Cox <rsc@golang.org>2008-10-07 12:31:31 -0700
commit2e35ca6c33cd9c089b6536e9405e2f90a8ec101c (patch)
tree133422e9724c37fc7aac2fcf9f1c52b230af51ef /src/lib/rand.go
parent5cff795078a27a56b69a1fa878b3b72be12b60a6 (diff)
downloadgolang-2e35ca6c33cd9c089b6536e9405e2f90a8ec101c.tar.gz
update code to follow new semicolon rules:
* 1. all statements and declarations are terminated by semicolons * 2. semicolons can be omitted at top level. * 3. semicolons can be omitted before and after the closing ) or } * on a list of statements or declarations. /home/rsc/bin/addsemi and then diff+tweak. R=r,gri OCL=16620 CL=16643
Diffstat (limited to 'src/lib/rand.go')
-rw-r--r--src/lib/rand.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/rand.go b/src/lib/rand.go
index ac5841147..8619cc48c 100644
--- a/src/lib/rand.go
+++ b/src/lib/rand.go
@@ -65,7 +65,7 @@ srand(seed int32)
for i := -20; i < LEN; i++ {
x = seedrand(x);
if i >= 0 {
- var u int64
+ var u int64;
u = int64(x) << 20;
x = seedrand(x);
u ^= int64(x) << 10;
@@ -121,7 +121,7 @@ nrand63(n int64) int64
return 0
}
max := int64((1<<63)-1 - (1<<63) % uint64(n));
- v := rand63()
+ v := rand63();
for v > max {
v = rand63()
}