Skip to content

Commit 655d32c

Browse files
committed
julia 1.0 compat
1 parent e8bd6b1 commit 655d32c

File tree

4 files changed

+8
-9
lines changed

4 files changed

+8
-9
lines changed

src/MacroTools.jl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
__precompile__(true)
21
module MacroTools
32

43
using Compat

src/examples/threading.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ macro >(exs...)
2222
isexpr(ex, :block) ? thread(x, rmlines(ex).args...) :
2323
Expr(:call, ex, x)
2424

25-
thread(x, exs...) = reduce(thread, x, exs)
25+
thread(x, exs...) = reduce(thread, exs, init=x)
2626

2727
esc(thread(exs...))
2828
end
@@ -42,7 +42,7 @@ macro >>(exs...)
4242
isexpr(ex, :block) ? thread(x, rmlines(ex).args...) :
4343
Expr(:call, ex, x)
4444

45-
thread(x, exs...) = reduce(thread, x, exs)
45+
thread(x, exs...) = reduce(thread, exs, init=x)
4646

4747
esc(thread(exs...))
4848
end

src/macro.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,13 @@ macro match(ex, lines)
5252
ex = $(esc(ex))
5353
end
5454

55-
@static if VERSION < v"0.7.0-"
56-
body = foldr((clause, body) -> makeclause(clause..., body),
57-
nothing, clauses(lines))
58-
else
55+
# @static if VERSION < v"0.7.0-"
56+
# body = foldr((clause, body) -> makeclause(clause..., body),
57+
# nothing, clauses(lines))
58+
# else
5959
body = foldr((clause, body) -> makeclause(clause..., body),
6060
clauses(lines); init=nothing)
61-
end
61+
# end
6262

6363
push!(result.args, body)
6464
return result

src/utils.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ function resyntax(ex)
388388
getindex(x_, i__) => :($x[$(i...)])
389389
tuple(xs__) => :($(xs...),)
390390
ctranspose(x_) => :($x')
391-
transpose(x_) => :($x.')
391+
# transpose(x_) => :($x.')
392392
_ => x
393393
end
394394
end

0 commit comments

Comments
 (0)