From 3f4e92b8e77eddffb0676f75135baf42e21d7174 Mon Sep 17 00:00:00 2001 From: fonsp Date: Fri, 27 Nov 2020 22:42:09 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=81=20Don't=20functionwrap=20eval/incl?= =?UTF-8?q?ude?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Project.toml | 2 +- src/analysis/ExpressionExplorer.jl | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Project.toml b/Project.toml index 1ec4f534b9..3554e9fadb 100644 --- a/Project.toml +++ b/Project.toml @@ -2,7 +2,7 @@ name = "Pluto" uuid = "c3e4b0f8-55cb-11ea-2926-15256bba5781" license = "MIT" authors = ["Fons van der Plas "] -version = "0.12.13" +version = "0.12.14" [deps] Base64 = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f" diff --git a/src/analysis/ExpressionExplorer.jl b/src/analysis/ExpressionExplorer.jl index ee1368fd61..2b7241e0c1 100644 --- a/src/analysis/ExpressionExplorer.jl +++ b/src/analysis/ExpressionExplorer.jl @@ -936,7 +936,8 @@ function can_be_function_wrapped(x::Expr) x.head === :macrocall || # we might want to get rid of this one, but that requires some work x.head === :struct || x.head === :abstract || - (x.head === :(=) && x.args[1] isa Expr && x.args[1].head === :call) # f(x) = ... + (x.head === :(=) && x.args[1] isa Expr && x.args[1].head === :call) || # f(x) = ... + (x.head === :call && (x.args[1] === :eval || x.args[1] === :include)) false else all(can_be_function_wrapped, x.args)