Navigation menu

WoW:API collectgarbage: Difference between revisions

Jump to navigation Jump to search
Added "count" as a parameter, found in mod "!!Warmup"
m (wowapi template added)
(Added "count" as a parameter, found in mod "!!Warmup")
Line 11: Line 11:


:;limit : Number - GC limit (in KiB). If omitted, defaults to zero, forcing garbage collection.
:;limit : Number - GC limit (in KiB). If omitted, defaults to zero, forcing garbage collection.
:;limit : "count" - will return the total kilobytes of memory used


== Example ==
== Example ==
  collectgarbage() -- Force garbage collection
  collectgarbage() -- Force garbage collection
  collectgarbage(131072) -- Set GC limit to 128 MiB
  collectgarbage(131072) -- Set GC limit to 128 MiB
collectgarbage("count") -- return kilobytes of memory in use, i.e. 2048 for 2 megabytes


== Note ==
== Note ==
Anonymous user