summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorEugen Wissner <belka@caraus.de>2018-04-08 05:59:14 +0200
committerEugen Wissner <belka@caraus.de>2018-04-08 05:59:14 +0200
commitd157e88b7afa397270faf2de84dc90187c6ec2e8 (patch)
tree72b0c209213645e5aa83868d22fc2aaaf9564c6d /source
parentd5064fa2b2bd98fa955e95eef0cf8b11d0aad341 (diff)
downloadtanya-d157e88b7afa397270faf2de84dc90187c6ec2e8.tar.gz
Fix import order in math.random
Diffstat (limited to 'source')
-rw-r--r--source/tanya/math/mp.d2
-rw-r--r--source/tanya/math/nbtheory.d2
-rw-r--r--source/tanya/math/package.d2
-rw-r--r--source/tanya/math/random.d10
4 files changed, 8 insertions, 8 deletions
diff --git a/source/tanya/math/mp.d b/source/tanya/math/mp.d
index 51816ef..8348998 100644
--- a/source/tanya/math/mp.d
+++ b/source/tanya/math/mp.d
@@ -5,7 +5,7 @@
/**
* Arbitrary precision arithmetic.
*
- * Copyright: Eugene Wissner 2016-2017.
+ * Copyright: Eugene Wissner 2016-2018.
* License: $(LINK2 https://www.mozilla.org/en-US/MPL/2.0/,
* Mozilla Public License, v. 2.0).
* Authors: $(LINK2 mailto:info@caraus.de, Eugene Wissner)
diff --git a/source/tanya/math/nbtheory.d b/source/tanya/math/nbtheory.d
index 6f8bfbd..889e10f 100644
--- a/source/tanya/math/nbtheory.d
+++ b/source/tanya/math/nbtheory.d
@@ -5,7 +5,7 @@
/**
* Number theory.
*
- * Copyright: Eugene Wissner 2017.
+ * Copyright: Eugene Wissner 2017-2018.
* License: $(LINK2 https://www.mozilla.org/en-US/MPL/2.0/,
* Mozilla Public License, v. 2.0).
* Authors: $(LINK2 mailto:info@caraus.de, Eugene Wissner)
diff --git a/source/tanya/math/package.d b/source/tanya/math/package.d
index 9b88a82..dc0ad3c 100644
--- a/source/tanya/math/package.d
+++ b/source/tanya/math/package.d
@@ -12,7 +12,7 @@
* be found in its submodules. $(D_PSYMBOL tanya.math) doesn't import any
* submodules publically, they should be imported explicitly.
*
- * Copyright: Eugene Wissner 2016-2017.
+ * Copyright: Eugene Wissner 2016-2018.
* License: $(LINK2 https://www.mozilla.org/en-US/MPL/2.0/,
* Mozilla Public License, v. 2.0).
* Authors: $(LINK2 mailto:info@caraus.de, Eugene Wissner)
diff --git a/source/tanya/math/random.d b/source/tanya/math/random.d
index 79399c1..a5786a7 100644
--- a/source/tanya/math/random.d
+++ b/source/tanya/math/random.d
@@ -5,7 +5,7 @@
/**
* Random number generator.
*
- * Copyright: Eugene Wissner 2016.
+ * Copyright: Eugene Wissner 2016-2018.
* License: $(LINK2 https://www.mozilla.org/en-US/MPL/2.0/,
* Mozilla Public License, v. 2.0).
* Authors: $(LINK2 mailto:info@caraus.de, Eugene Wissner)
@@ -234,9 +234,12 @@ else version (SecureARC4Random)
else version (Windows)
{
import core.sys.windows.basetsd : ULONG_PTR;
+ import core.sys.windows.winbase : GetLastError;
+ import core.sys.windows.wincrypt;
import core.sys.windows.windef : BOOL, DWORD, PBYTE;
+ import core.sys.windows.winerror : NTE_BAD_KEYSET;
import core.sys.windows.winnt : LPCSTR, LPCWSTR;
- import core.sys.windows.wincrypt;
+
private extern(Windows) @nogc nothrow
{
BOOL CryptGenRandom(HCRYPTPROV, DWORD, PBYTE);
@@ -247,9 +250,6 @@ else version (Windows)
private bool initCryptGenRandom(scope ref HCRYPTPROV hProvider) @nogc nothrow @trusted
{
- import core.sys.windows.winbase : GetLastError;
- import core.sys.windows.winerror : NTE_BAD_KEYSET;
-
// https://msdn.microsoft.com/en-us/library/windows/desktop/aa379886(v=vs.85).aspx
// For performance reasons, we recommend that you set the pszContainer
// parameter to NULL and the dwFlags parameter to CRYPT_VERIFYCONTEXT