For the directory of libraries I try to automate the registration process of functions as much as possible.
One of the function characteristics that's going to be registered is whether it employs user code in JavaScript.
So I wrote a JavaScript-detector for functions (blocks, scripts). It searches the definition of a function, plus definitions of custom functions called by the function, etc.
I wonder if anyone can find a flaw in it: (if there is one, it's not intentional!)
If you want to try it yourself, see the link in post #3.
BTW the function itself should of course have been a predicate, not a reporter. I already fixed that.
Paradoxically, since it searches code for JAVASCRIPT FUNCTION, the above JavaScript detector function will report itself containing JavaScript code (which is not true). Kurt Gödel would have liked it .