forked from mirrors/org-mode
A "functional-style" source block is one in which the name is followed immediately by a parenthesised argument. An example is the following "function", which generates n uniform random numbers: \#+srcname: rand(n) \#+begin_src R runif(n) \#+end_src With these changes, such source blocks are passed over to the export machinery in the following form: \#+begin_src org-babel-lob <function-def-keyword> rand(n): \#+end_src \#+begin_src R <switches> <indent>runif(n) \#+end_src where <function-def-keyword> is the value of org-babel-function-def-export-keyword, which defaults to "function", <switches> are the src block switches that belonged to the original block, and <indent> is the whitespace indent of the function body, the width of which is determined by org-babel-function-def-export-indent. org-babel-lob is a simple major mode responsible for fontification of the blocks corresponding to the function definition line (as opposed to the function body). |
||
---|---|---|
.. | ||
lisp | ||
library-of-babel.org |