/usr/share/SuperCollider/HelpSource/Classes/FunctionDef.schelp is in supercollider-common 1:3.8.0~repack-2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 | class::FunctionDef
summary:: FunctionDefs contain code which can be executed from a Function.
categories::Core>Kernel
related::Classes/Function
description::
subsection:: Related Keywords
method:: thisFunctionDef
The global pseudo-variable code::thisFunctionDef:: always evaluates to the
current enclosing FunctionDef.
See also: link::Classes/Function#.thisFunction#thisFunction::
instanceMethods::
subsection::Accessing
Even though it is possible to change the values in the various arrays that define the FunctionDef,
you should not do it, unless you like to crash.
method::code
Get the byte code array.
code::
{ |a = 9, b = 10, c| a + b }.def.code;
::
method::sourceCode
Get the source code string.
code::
{ |a = 9, b = 10, c| a + b }.def.sourceCode.postcs;
::
method::context
Get the enclosing FunctionDef or Method.
method::findReferences
return a list of all references to a given symbol.
method::argNames
Get the Array of Symbols of the argument names.
code::
{ |a = 9, b = 10, c| a + b }.def.argNames;
::
method::prototypeFrame
Get the array of default values for argument and temporary variables.
code::
{ |a = 9, b = 10, c| a + b }.def.prototypeFrame;
::
method::varNames
Get the Array of Symbols of the local variable names.
code::
{ |a = 9, b = 10, c| var x = 9; a + b + x }.def.varNames;
::
method::argumentString
Return a string that contains arguments and their default values for embedding in a string
code::
{ |a = 9, b = 10, c| a + b }.def.argumentString;
::
method::makeEnvirFromArgs
Get the Array of Symbols of the local variable names.
code::
{ |a = 9, b = 10, c| a + b }.def.makeEnvirFromArgs;
::
subsection::Utilities
method::dumpByteCodes
"Disassemble" and post the FunctionDef's byte code instructions to the text window.
|