Earlier when I said "crashing", it meant "segmentation fault". I suspect its because of misuse of "combine"
I just tried with 5.2.2 and it appears that application is not crashing.
I am also receiving error message as "(c:\work\test2.lua:2: attempt to call global 'call_me' (a nil value))"....I wasn't getting this on 5.2.1
I tried using "combine" with n=2. i.e test2 and call_me ( hoping that its on the stack ). did not work.
I also tried, appending function definition to "return" in test.lua. something like:
str = "return \"function call_me()\\nprint(\\\"how about this?\\\")\\nend\\n\"\n"
load(str) //it didn't matter if I do load(str)()
when I observe my dumped buffer, I could only see definition of test2().
Apart from this, just for an experiment, I did following thing using c apis:
1: load call_me function //explicitly loading this using c api
2: load test2 function
3: combine() with n=2
4:dump to buffer
5: in different state load this buffer
6: call test2, and we are good