File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ function __init__()
36
36
" Either use Julia v1.0.x, or v1.3.0 or higher.\n " *
37
37
" For 1.3 onwards, please also set the environment variable `JULIA_COPY_STACKS` to be `1` or `yes`" )
38
38
end
39
- if VERSION ≥ v " 1.3-" && ! JULIA_COPY_STACKS
39
+ if VERSION ≥ v " 1.3-" && ! Sys . iswindows () && ! JULIA_COPY_STACKS
40
40
@warn (" JavaCall needs the environment variable `JULIA_COPY_STACKS` to be `1` or `yes`.\n " *
41
41
" Calling the JVM may result in undefined behavior." )
42
42
end
Original file line number Diff line number Diff line change @@ -168,7 +168,11 @@ const ROOT_TASK_ERROR = JavaCallError(
168
168
169
169
# JavaCall must run on the root Task or JULIA_COPY_STACKS is enabled
170
170
isroottask () = JULIA_COPY_STACKS || Base. roottask === Base. current_task ()
171
- assertroottask () = isroottask () ? nothing : throw (ROOT_TASK_ERROR)
171
+ @static if Sys. iswindows ()
172
+ assertroottask () = nothing
173
+ else
174
+ assertroottask () = isroottask () ? nothing : throw (ROOT_TASK_ERROR)
175
+ end
172
176
173
177
isloaded () = isdefined (JavaCall, :jnifunc ) && isdefined (JavaCall, :penv ) && penv != C_NULL
174
178
You can’t perform that action at this time.
0 commit comments