We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run this simple script 10000 times and you'll end up eating your memory.
DEF TEST() PRINT "WHATEVER"; ENDDEF PRINT "HELLO WORLD";
Runtime logs:
22:14:00.174 -> Exe /last.bas Tout: 10000ms Heap: 204564 << 22:14:00.206 -> Exe Loaded /last.bas Tout: 10000ms Heap: 195084 22:14:00.206 -> Exe /last.bas Tout: 10000ms Heap: 204224 << 22:14:00.237 -> Exe Loaded /last.bas Tout: 10000ms Heap: 194744 22:14:00.237 -> Exe /last.bas Tout: 10000ms Heap: 203884 << 22:14:00.237 -> Exe Loaded /last.bas Tout: 10000ms Heap: 194408 ... 22:15:05.877 -> Exe Loaded /last.bas Tout: 10000ms Heap: 155952 22:15:05.877 -> Exe /last.bas Tout: 10000ms Heap: 165012<< 22:15:05.909 -> Exe Loaded /last.bas Tout: 10000ms Heap: 155600 22:15:05.909 -> Exe /last.bas Tout: 10000ms Heap: 164672 << 22:15:05.909 -> Exe Loaded /last.bas Tout: 10000ms Heap: 155268 22:15:05.941 -> Exe /last.bas Tout: 10000ms Heap: 164332 << 22:15:05.941 -> Exe Loaded /last.bas Tout: 10000ms Heap: 154916
As soon as you remove the DEF - ENDDEF block, you're fine, see below:
DEF - ENDDEF
REM DEF TEST() REM PRINT "WHATEVER"; REM ENDDEF PRINT "HELLO WORLD";
Runtime log:
22:39:52.603 -> Exe /last.bas Tout: 10000ms Heap: 228608 22:39:52.603 -> Exe Loaded /last.bas Tout: 10000ms Heap: 218596 22:39:52.603 -> HELLO WORLD 22:39:52.603 -> Exe /last.bas Tout: 10000ms Heap: 228508 <<<<<<<< 22:39:52.641 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.641 -> HELLO WORLD 22:39:52.641 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.666 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.666 -> HELLO WORLD 22:39:52.666 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.666 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.666 -> HELLO WORLD 22:39:52.699 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.699 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.699 -> HELLO WORLD 22:39:52.699 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.731 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.731 -> HELLO WORLD 22:39:52.731 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.731 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.764 -> HELLO WORLD 22:39:52.764 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.764 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.764 -> HELLO WORLD 22:39:52.764 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.796 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.796 -> HELLO WORLD 22:39:52.796 -> Exe /last.bas Tout: 10000ms Heap: 228508 22:39:52.828 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.828 -> HELLO WORLD 22:39:52.828 -> Exe /last.bas Tout: 10000ms Heap: 228508 <<<<<<<< 22:39:52.828 -> Exe Loaded /last.bas Tout: 10000ms Heap: 220832 22:39:52.828 -> HELLO WORLD
The text was updated successfully, but these errors were encountered:
This happens when MB_ENABLE_LAMBDA is undefined / used.
MB_ENABLE_LAMBDA
Enabled by default. Compiles with lambda (anonymous function) support if this macro is defined.
in my_basic.h undefine MB_ENABLE_LAMBDA
my_basic.h
// #ifndef MB_ENABLE_LAMBDA // # define MB_ENABLE_LAMBDA // #endif /* MB_ENABLE_LAMBDA */
Sorry, something went wrong.
So based on your test there's mem leak if lambda is disabled?
Correct, when MB_ENABLE_LAMBDA is not defined and DEF used in the script.
MB_ENABLE_LAMBDA is not defined
DEF
No branches or pull requests
Run this simple script 10000 times and you'll end up eating your memory.
Runtime logs:
As soon as you remove the
DEF - ENDDEF
block, you're fine, see below:Runtime log:
The text was updated successfully, but these errors were encountered: