Skip to content

Commit 246d049

Browse files
authored
Merge pull request #97 from staticfloat/sf/inexprfix
Fix `inexpr()` failing to find things due to its return value
2 parents fd517a2 + e0f7a64 commit 246d049

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/utils.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,10 @@ inside `expr`.
128128
function inexpr(ex, x)
129129
result = false
130130
MacroTools.postwalk(ex) do y
131-
y == x && (result = true)
131+
if y == x
132+
result = true
133+
end
134+
return y
132135
end
133136
return result
134137
end

0 commit comments

Comments
 (0)