Skip to content
This repository was archived by the owner on Mar 12, 2021. It is now read-only.

Commit 9ae7b88

Browse files
committed
Use 'using' when we don't actually extend a method.
1 parent b9b3077 commit 9ae7b88

File tree

17 files changed

+39
-37
lines changed

17 files changed

+39
-37
lines changed

src/blas/CUBLAS.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module CUBLAS
22

33
using CUDAapi
44

5-
import CUDAdrv: CUDAdrv, CuContext, CuStream_t, CuPtr, PtrOrCuPtr, CU_NULL, devices
5+
using CUDAdrv: CUDAdrv, CuContext, CuStream_t, CuPtr, PtrOrCuPtr, CU_NULL, devices
66

77
import CUDAnative
88

src/deprecated.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Deprecated functionality
22

3-
import Base: @deprecate_binding
3+
using Base: @deprecate_binding
44

55
@deprecate_binding BLAS CUBLAS
66
@deprecate_binding FFT CUFFT

src/dnn/CUDNN.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ module CUDNN
33
using CUDAapi
44
using CUDAapi: libraryPropertyType
55

6-
import CUDAdrv: CUDAdrv, CuContext, CuPtr, PtrOrCuPtr, CU_NULL, CuStream_t
6+
using CUDAdrv
7+
using CUDAdrv: CuContext, CuPtr, PtrOrCuPtr, CU_NULL, CuStream_t
78

89
import CUDAnative
910

src/dnn/conv.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import NNlib: DenseConvDims
1+
using NNlib: DenseConvDims
22

33

44
# descriptor

src/dnn/pooling.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import NNlib: PoolDims
1+
using NNlib: PoolDims
22

33

44
# descriptor

src/dnn/rnn.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
# GRU: [weight, bias] × [input, hidden] × [reset, update, newmem]
99
# LSTM: [weight, bias] × [input, hidden] × [input, forget, newmem, output]
1010

11-
import LinearAlgebra: copy_transpose!
11+
using LinearAlgebra: copy_transpose!
1212

1313
function params(w::CuVector, input, hidden, n = 1)
1414
slice(offset, shape) = reshape(view(w, offset.+(1:prod(shape))), shape)

src/memory/binned.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ module BinnedPool
1717
# or just use unified memory for all allocations.
1818
# - per-device pools
1919

20-
import ..@pool_timeit, ..actual_alloc, ..actual_free
20+
using ..CuArrays: @pool_timeit, actual_alloc, actual_free
2121

2222
using CUDAdrv
2323

src/memory/dummy.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module DummyPool
22

33
# dummy allocator that passes through any requests, calling into the GC if that fails.
44

5-
import ..@pool_timeit, ..actual_alloc, ..actual_free
5+
using ..CuArrays: @pool_timeit, actual_alloc, actual_free
66

77
using CUDAdrv
88

src/memory/simple.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module SimplePool
22

33
# simple scan into a list of free buffers
44

5-
import ..@pool_timeit, ..actual_alloc, ..actual_free
5+
using ..CuArrays: @pool_timeit, actual_alloc, actual_free
66

77
using CUDAdrv
88

src/memory/split.jl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,16 @@ module SplittingPool
22

33
# scan into a sorted list of free buffers, splitting buffers along the way
44

5-
import ..CuArrays, ..@pool_timeit
5+
using ..CuArrays
6+
using ..CuArrays: @pool_timeit
67

78
using DataStructures
89

910
using CUDAdrv
1011

1112
# use a macro-version of Base.lock to avoid closures
1213
if VERSION >= v"1.3.0-DEV.555"
13-
import Base.@lock
14+
using Base: @lock
1415
else
1516
macro lock(l, expr)
1617
quote

0 commit comments

Comments
 (0)