yLuaz‘g‚Ýž‚ÝŒnŒ¾Œ ..
353:ƒfƒtƒHƒ‹ƒg‚Ì–¼–³‚µ‚³‚ñ
09/10/28 18:17:32
ƒŠƒX‚̃oƒO”Œ©B
setdebughook‚ðŽdŠ|‚¯‚½ó‘Ô‚Å_callƒƒ^ƒƒ\ƒbƒh‚ðƒR[ƒ‹‚·‚邯ހ‚ÊB(SQVM‚łʂé‚Û”¶)
‚¿‚Ȃ݂ÉdebughookŠÖ”‚Ì’†g‚ð‹ó‚É‚µ‚Ä‚à“¯—l‚Å‚·B
ŒöŽ®ƒtƒH[ƒ‰ƒ€‚ÌC‚ð•´Ž¸‚µ‚Ä‚µ‚Ü‚Á‚½‚̂ŒN‚©•ñ‚½‚Ì‚Þ
URLØÝ¸(squirrel-lang.org)
function debughook(event_type, sourcefile, line, funcname) {
@local fname = funcname ? funcname : "unknown";
@local srcfile = sourcefile ? sourcefile : "unknown";
@::print(::format("%s:%d: [DEBUGHOOK:%c] %s\n", srcfile, line, event_type, fname));
}
::setdebughook(debughook);
class FOO {
@function test() { ::print("FOO::test()\n"); }
@function _call(orig_this) { ::print("FOO::_call()\n"); }
};
local foo = FOO();
foo.test();
::setdebughook(null);
foo();
::setdebughook(debughook);
foo(); // Segmentation fault (core dumped)
ŽŸƒy[ƒW‘±‚«‚ð•\ަ1‚ð•\ަÅVƒŒƒX•\ަƒXƒŒƒbƒh‚ÌŒŸõ—ÞŽ—ƒXƒŒˆê——˜b‘è‚̃jƒ…[ƒX‚¨‚Ü‚©‚¹ƒŠƒXƒg¥ƒIƒvƒVƒ‡ƒ“‚ð•\ަ‰É‚‚Ԃµ2ch
4275“ú‘O‚ÉXV/247 KB
’S“–:undef