Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: RFC: Examples in the auto-documentation

From: greggirwin:mindspring at: 24-Dec-2002 12:37

Hi Ammon, AJ> I based my desire for this functionality on the fact that I can sit at AJ> the console and write my entire program without touching a text book or any AJ> other source for information, just the console. And that is because of the AJ> auto-documented nature of REBOL. If there was some examples placed in with AJ> it then my productivity would literally double in most situations. Anyone AJ> else with similar experiences? OK, how about this as a five-minute workaround: Put the ref-data.r file, used by view-ref.r, somewhere handy - maybe the same dir as REBOL. Load it, maybe in user.r ref: load %ref-data.r Write a func to do what you want (also added to user.r?) eg: func ['word] [help :word print last select ref word] Call it as needed
>> eg <
USAGE: value1 < value2 DESCRIPTION: Returns TRUE if the first value is less than the second value. < is an op value. ARGUMENTS: value1 -- (Type: any) value2 -- (Type: any) Returns FALSE for all other values. An error will occur if the values are not of the same datatype. For string-based datatypes, the sorting order is used for comparison with character casing ignored (uppercase lowercase). print "abc" < "abcd" print 15-June-1999 < 14-June-1999 print < print 1:30 < 2:00 -- Gregg