Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Rebol
Index -> General Programming
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
btiffin




PostPosted: Sat Jan 26, 2008 11:52 am   Post subject: Rebol

Hello,

There is a new release of the REBOL programming language in active development. Carl Sassenrath (responsible for the Amiga operating system) is hard at work with the third major version of the Relative Expression Based Object Language. R3. R3 went to public alpha status on January 8th.

If you ever wanted to influence the design and implementation of a language, Carl is very open to suggestions and feedback.

http://www.rebol.com is the home page
http://www.rebol.org is the public script library
http://www.rebol.net is the developer resource page
http://www.reboltalk.com is one of the public discussion forums

Alpha release announcement at http://www.rebol.com/article/0347.html

The new REBOL release 3 is alpha, so before trying it out, please follow the Download links from rebol.com for the current release verions of REBOL 2 just to get your feet wet with this somewhat under utilized and very powerful system.

REBOL 2 comes in two main flavours, REBOL/Core and REBOL/View. REBOL/Core is for console and CGI applications. REBOL/View includes a very simple yet powerful GUI builder. Multiple platforms are supported, but it's mainly GNU/Linux, Windows and Mac/OS.

For example this script is a graphical Hello World with a close button (on all supported platforms)
REBOL [
Title: "Sample"
]
view layout [text "Hello REBOL World" button "Close" [unview/all halt]]


This script will display the html of the REBOL website
REBOL [] print read http://www.rebol.com

Thanks for listening.
Brian Tiffin
REBOL programmer and evangelist, just wanting to spread the word.
Sponsor
Sponsor
Sponsor
sponsor
Dan




PostPosted: Sat Jan 26, 2008 4:58 pm   Post subject: RE:Rebol

Can you tell us more about REBOL btiffin? Like what advantages it might have over other languages or a comparison to them? Who is this language aimed at?
Computer Science Canada Help with programming in C, C++, Java, PHP, Ruby, Turing, VB and more!
btiffin




PostPosted: Mon Jan 28, 2008 2:23 pm   Post subject: Re: Rebol

Absolutely; I grew up a polyFORTH programmer but my quest to learn programming enviroments lead me to REBOL.

REBOL is a marvelous little gem of a scripting language. First the evalgelising. REBOL makes network and graphical programming a breeze. It is interpreted, so it is not a systems programming tool but aside trom that, covers most general programming domains. REBOL is freely redistributable but portions are not Open Source. The whole system is a 600K download. Carl Sassenrath the language designer is in California, but REBOL is used all over the world with a fair number of the users being from France.

Compares well to Ruby, Python, Forth, Lisp, Java and others (in that apps will usually be smaller in terms of lines of code).

REBOL is rich in datatypes, highly reflective, interactive and very network capable. Syntax is based on context, and there are a few design issues that make it different from most programming environments. It's graphics engine is very powerful and easy to use.

Datatypes include computer science related as well as abstract types. REBOL is value based, where values have a type and a contents. There is integer!, decimal!, binary! and the expected numerical types as well as string!, char!, and with Release 3, full Unicode support. The power comes with some of the other lexically defined datatypes. email!, url! for the network, block!, map!, object! and struct! as some of the structures and then types like money!.

send user@host.moc "This string will be sent as email"

a: [this is a block of REBOL word! values $23.00 will load as money! http://www.rebol.com will load as url!]

Conceptually, REBOL is based on series! data. Series in REBOL cover such things as string!, block! and other abstracted types such as port!. Functions such as HEAD, TAIL, NEXT, BACK, SKIP are used to traverse series and access functions such as FIRST, SECOND, NINTH or PICK.

REBOL includes a very powerful pattern matching function called PARSE. Parse allows for REBOL dialects. Dialects can be user defined domain specific languages or syntax helper structures.

REBOL functions, (type function!) are fixed parameter but can include refinements for optional arguments. Source code for mezzanine and user functions is available from the console with the SOURCE fucntion.

REBOL object! structures are prototyped based objects. Namespace and value bindings are part of the object! concept.

REBOL is currently on release 2, with a /CORE and a /VIEW version, both of which come with a console, but /CORE is well suited to running CGI and Server applications. /VIEW adds the graphics.

A gui is REBOL can be as short as view layout [text "Hello World"] and a form can be posted with something as short as

view layout [
h1 "Contact App"
label "Name" name: field
label "Phone" phone: field
button "Find" [lookup name phone]
button "Add" [create name phone]
]

The Visual Interface Dialect can also support animations and far more than just forms.

Webservers, databases and many other applications are available. rebol.org the public script library site is supported completely through REBOL CGI scripts.

With REBOL release 2, some professional featrures (access to run time libraries for one) are commercial. That will change with the third release. Much of the fast and furious REBOL communications occur inside a REBOL application called AltMe (Alternate Messaging) and the main REBOL3 world is by invitation. Dropping a note on reboltalk.com can help getting in.

Why might a compsci.ca reader care? Aside from REBOL being a very capable entry on any programmers utility belt, REBOL is on the brink of release 3. Not a bad time to pick up this beauty of a tool kit, language, enviroment.

Some key documents can be found at http://rebol.com/docs/core23/rebolcore.html (the core manual online)
and http://rebol.com/rebolsteps.html (REBOL in ten steps, more in depth than just an intro but a short read).

Cheers,
Brian Tiffin
btiffin




PostPosted: Thu Jan 31, 2008 3:32 am   Post subject: Re: Rebol

Hi,

More REBOL evangelizing.

Here is a web server in one line of code ... not exceptionally readable REBOL. It serves files out of the current working directory

code:

REBOL [] secure[net allow library throw shell throw file throw %. [allow read]]p: open/lines tcp://:80 forever[attempt[s: length? b: read/binary to-file next pick parse pick c: p/1 1 none 2 write-io c b: rejoin[#{}"HTTP/1.0 200 OK^M^JServer: Rebol^M^JContent-length: "s"^M^JContent-type: text/html^M^J^M^J"b]length? b close c]]


Author: Cal Dixon

How about a one line paint program?

code:

REBOL [] view layout[s: box black 400x400 feel[engage: func[f a e][if find[down over]a[append s/effect/draw e/offset show s]if a = 'up[append s/effect/draw 'line]]]effect[draw[line]]]


Author: Nick Antonaccio

How about a digital clock?

code:

REBOL [] view layout[origin 0 t: h1 red black (to string! now/time) rate 1 feel[engage: [t/text: now/time show t]]]


Author: Ammon Johnson

These examples are more useful for demonstration than actual function, but it does highlight the power of my favourite programming environment.

Cheers,
Brian Tiffin
Display posts from previous:   
   Index -> General Programming
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 4 Posts ]
Jump to:   


Style:  
Search: