diff options
author | 2019-09-29 15:30:18 +0200 | |
---|---|---|
committer | 2019-09-29 09:30:18 -0400 | |
commit | ed2b7e5ef1626c0d6318b6ea71897efbb4356277 (patch) | |
tree | 62a84a4a2c804922839dbfa60ec664b84beaaee0 /3rdparty/genie/src/base/io.lua | |
parent | 1bd1288c9e17bdba9544d1e56be7618106fece7e (diff) |
Synced with GENie upstream revision e78d6c1 (#5631)
* Synced with GENie upstream revision e78d6c1
* Add Visual Studio 2019 support
* Fix hardcoded -m64
* Switch appveyor to Visual Studio 2019
* Fix genie being built as 32-bit
* MSVC build is known to be broken currently. Let it fail until all the known issues are fixed.
* Update the packages before building
* Build with 3 threads
Appveyor VMs have only 2 cores and 8 GB RAM.
* Enable caching of pacman cache
Diffstat (limited to '3rdparty/genie/src/base/io.lua')
-rw-r--r-- | 3rdparty/genie/src/base/io.lua | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/3rdparty/genie/src/base/io.lua b/3rdparty/genie/src/base/io.lua index 9ebc03d07e8..11c2a28924d 100644 --- a/3rdparty/genie/src/base/io.lua +++ b/3rdparty/genie/src/base/io.lua @@ -15,22 +15,26 @@ _esc = _escaper -- -- Prepare to capture the output from all subsequent calls to io.printf(), --- used for automated testing of the generators. +-- used for automated testing of the generators. Returns the previously +-- captured text. -- function io.capture() + local prev = io.captured io.captured = '' + return prev end -- --- Returns the captured text and stops capturing. +-- Returns the captured text and stops capturing, optionally restoring a +-- previous capture. -- - function io.endcapture() + function io.endcapture(restore) local captured = io.captured - io.captured = nil + io.captured = restore return captured end |