Skip to content

Commit 18578bb

Browse files
Format .jl files (#239)
Co-authored-by: yeesian <[email protected]>
1 parent 678123e commit 18578bb

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/utils.jl

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,8 @@ macro convert(args...)
5353
type1_string = replace(string(type1_symbol), "." => "_")
5454
type2_string = replace(string(type2_symbol), "." => "_")
5555
type1_isenum_and_type2_equaldatatype_or_isaunionall =
56-
(eval(type1_symbol) <: Enum) && (
57-
(eval(type2_symbol) == DataType) ||
58-
(eval(type2_symbol) isa UnionAll)
59-
)
56+
(eval(type1_symbol) <: Enum) &&
57+
((eval(type2_symbol) == DataType) || (eval(type2_symbol) isa UnionAll))
6058
type1 = esc(type1_symbol)
6159
type2 = esc(type2_symbol)
6260
fwd_map = Expr[Expr(:tuple, esc.(a.args)...) for a in args[2:end]]
@@ -86,7 +84,8 @@ macro convert(args...)
8684
# Reverse conversion
8785
if type1_isenum_and_type2_equaldatatype_or_isaunionall
8886
for stypes in rev_to_enum_map
89-
eval(type2_symbol) isa UnionAll && @assert eval(stypes[1].args[1]) <: eval(type2_symbol)
87+
eval(type2_symbol) isa UnionAll &&
88+
@assert eval(stypes[1].args[1]) <: eval(type2_symbol)
9089
push!(
9190
result_expr.args,
9291
:(

0 commit comments

Comments
 (0)