comparison LazyTensors/src/lazy_operations.jl @ 195:5413067d2c4a boundary_conditions

Remove semicolon and some unneeded exports
author Jonatan Werpers <jonatan@werpers.com>
date Thu, 20 Jun 2019 23:14:46 +0200
parents d30d42a11566
children b3c252280a19
comparison
equal deleted inserted replaced
194:d30d42a11566 195:5413067d2c4a
112 @inline *̃(a::AbstractArray{T,D},b::AbstractArray{T,D}) where {T,D} = LazyElementwiseOperation{T,D,:*}(a,b) 112 @inline *̃(a::AbstractArray{T,D},b::AbstractArray{T,D}) where {T,D} = LazyElementwiseOperation{T,D,:*}(a,b)
113 @inline /̃(a::AbstractArray{T,D},b::AbstractArray{T,D}) where {T,D} = LazyElementwiseOperation{T,D,:/}(a,b) 113 @inline /̃(a::AbstractArray{T,D},b::AbstractArray{T,D}) where {T,D} = LazyElementwiseOperation{T,D,:/}(a,b)
114 114
115 # Abstract type for which the normal operations are defined by their 115 # Abstract type for which the normal operations are defined by their
116 # lazy counterparts 116 # lazy counterparts
117 abstract type LazyArray{T,D} <: AbstractArray{T,D} end; 117 abstract type LazyArray{T,D} <: AbstractArray{T,D} end
118 118
119 Base.:+(a::LazyArray{T,D},b::AbstractArray{T,D}) where {T,D} = a +̃ b 119 Base.:+(a::LazyArray{T,D},b::AbstractArray{T,D}) where {T,D} = a +̃ b
120 Base.:+(a::AbstractArray{T,D}, b::LazyArray{T,D}) where {T,D} = b + a 120 Base.:+(a::AbstractArray{T,D}, b::LazyArray{T,D}) where {T,D} = b + a
121 Base.:-(a::LazyArray{T,D},b::AbstractArray{T,D}) where {T,D} = a -̃ b 121 Base.:-(a::LazyArray{T,D},b::AbstractArray{T,D}) where {T,D} = a -̃ b
122 Base.:-(a::AbstractArray{T,D}, b::LazyArray{T,D}) where {T,D} = a -̃ b 122 Base.:-(a::AbstractArray{T,D}, b::LazyArray{T,D}) where {T,D} = a -̃ b
124 Base.:*(a::AbstractArray{T,D},b::LazyArray{T,D}) where {T,D} = b * a 124 Base.:*(a::AbstractArray{T,D},b::LazyArray{T,D}) where {T,D} = b * a
125 # TODO: / seems to be ambiguous 125 # TODO: / seems to be ambiguous
126 # Base.:/(a::LazyArray{T,D},b::AbstractArray{T,D}) where {T,D} = a /̃ b 126 # Base.:/(a::LazyArray{T,D},b::AbstractArray{T,D}) where {T,D} = a /̃ b
127 # Base.:/(a::AbstractArray{T,D},b::LazyArray{T,D}) where {T,D} = a /̃ b 127 # Base.:/(a::AbstractArray{T,D},b::LazyArray{T,D}) where {T,D} = a /̃ b
128 128
129 export +̃, -̃, *̃, /̃, +, -, * #, / 129 export +̃, -̃, *̃, /̃
130
131
132 130
133 131
134 132
135 # TODO: Write tests and documentation for LazyTensorMappingComposition 133 # TODO: Write tests and documentation for LazyTensorMappingComposition
136 # struct LazyTensorMappingComposition{T,R,K,D} <: TensorMapping{T,R,D} 134 # struct LazyTensorMappingComposition{T,R,K,D} <: TensorMapping{T,R,D}