From ac5038d8690f2a75d385ee60f0a521c861848a1e Mon Sep 17 00:00:00 2001 From: Jameson Nash Date: Fri, 10 Jan 2020 11:51:30 -0500 Subject: [PATCH] revert breaking change to GC.gc() Removes the breaking part of b0ed147c5cf0566019ff08755af71eb5649411bc from PR #34303 --- base/gcutils.jl | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/base/gcutils.jl b/base/gcutils.jl index 95de3137deda7..11528e948f294 100644 --- a/base/gcutils.jl +++ b/base/gcutils.jl @@ -53,15 +53,15 @@ module GC GC.gc() GC.gc(full::Bool) -Perform garbage collection. The argument `full` determines the kind of collection: A full -collection scans all objects, while an incremental collection only scans so-called young -objects and is much quicker. If called without an argument, heuristics are used to determine -which type of collection is needed. +Perform garbage collection. The argument `full` determines the kind of +collection: A full collection (default) sweeps all objects, which makes the +next GC scan much slower, while an incremental collection may only sweep +so-called young objects. !!! warning Excessive use will likely lead to poor performance. """ -gc() = ccall(:jl_gc_collect, Cvoid, (Cint,), 0) +gc() = ccall(:jl_gc_collect, Cvoid, (Cint,), 1) gc(full::Bool) = ccall(:jl_gc_collect, Cvoid, (Cint,), full ? 1 : 2) """