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

[REBOL] Re: REBOL Newbie tries to convert C source to REBOL (long posting) Part

From: AJMartin:orcon at: 24-Dec-2003 22:49

Mike wrote:
> If instead the editor would be doing background parsing and watch me
create an object or button it could really support me by displaying all possible options with that element. Hi, Mike. I can see that you like the idea of C and Java IDEs. Unfortunately, Rebol script is way too malleable and versatile for a IDE to tease it apart and offer help. That's because words can mean many different things in the same script, as opposed to C or Java where a word means one thing and one thing only. For example when I write (in C#, but the principle still applies): class Mesh { static string title = "Mesh"; static public string Title { get { A C# IDE would realise that I'm writing a accessor method and can automatically produce the appropriate "cruft" like ";" "{" and "}" and even suggest apropriate text for me to type in or select from a drop-down list. But with Rebol and it's support for dialects where words mean what you want them to mean, a IDE for Rebol is build upon "shifting sand". Consider a IDE trying to understand my Envelope function: Envelope: func [Head [block!] Body [block!]] [ print rejoin [ "Content-Type: " 'text/html newline newline ML compose/deep [<?xml version="1.0" encoding="ISO-8859-1" ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg.dtd"> html [ head [(Head)] body [(Body)] ] ] ] quit ] Here's the 'help function on 'head:
>> help head
USAGE: HEAD series DESCRIPTION: Returns the series at its head. HEAD is an action value. ARGUMENTS: series -- (Type: series port) And on my 'envelope function:
>> help envelope
USAGE: ENVELOPE Head Body DESCRIPTION: (undocumented) ARGUMENTS: Head -- (Type: block) Body -- (Type: block) Note that the 'head inside the 'Envelope function means create a XHTML head tag and the 'Head inside the parenthesis means to insert the contents of the first parameter 'Head to the 'Envelope function! How would the IDE know this with out being artificially intelligent? :)
> P.S.: Does this list support attachments (ascii) ? Cause, actually I
attached some code with my last mail but didn't see it on line (listview) - are the attachments extracted ? I think that attachements are absorbed without being passed on. Andrew J Martin Speaking in tongues and performing miracles. ICQ: 26227169 http://www.rebol.it/Valley/ http://valley.orcon.net.nz/ http://Valley.150m.com/