Source

angerangel edited this page Jan 7, 2013 · 1 revision
Clone this wiki locally

USAGE

   SOURCE 'word

DESCRIPTION

Prints the source code for a word.

SOURCE is a function value.

ARGUMENTS

  • word (word! path!)

#SOURCE

source: make function! [  [
    "Prints the source code for a word."
    'word [word! path!]
][
    if not value? word [print [word "undefined"] exit]
    print head insert mold get word reduce [word ": "]
    exit
] ]