// Syntax: time { doFunnyStuff(); } !752 p { L tok = tokMainJava(); tok = replaceKeywordBlock(tok, // keyword to match "time", // beginning of replacement block "{ long __time_startTime = now(); try { ", // end of replacement block "} finally { __time_startTime = now()-__time_startTime; saveTiming(__time_startTime); } }"); saveMainJava(tok); }