Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I also tried to learn the "PARSE dialect" (the DSL coding mechanism of REBOL/Red), as this is what's often claimed to be the crucial differentiating factor (the "main idea") of REBOL/Red - but I failed, because of what OP mentions. The REBOL docs feel to me more like an example-based guide, than a solid RTFM-grade manual. I find such a guide OK and valuable as a tutorial, a starting point, and to teach idioms and mindset; but then I need a reference manual to clarify all details and fully explore the topic. Also read some third-party articles on PARSE, but none of them were comprehensive enough (AFAIR, mostly being tutorial-like too). Lua and Go do it well in my opinion - they both provide a solid tutorial-like experience, but then a full-blown, well written reference manual too.


There are two third-party reference-like (but non-authoritative) documentations that I know of [0][1]. A Red reference documentation for Parse will be available later this year.

[0] https://en.wikibooks.org/wiki/REBOL_Programming/Language_Fea...

[1] https://github.com/gchiu/rebol.net/blob/master/wikipedia/Par...


Thanks Nenad! :) The links indeed look interesting, at least at a first glance, though it seems not quite clear to me which keywords are R2 vs. R3 (proposals?) vs. Red, especially in the link marked as [1]. Still, at least that's something, will certainly be very useful if I try to understand PARSE again at some point in future. And I'm very happy to hear you're planning some more comprehensive docs for Red!


Good to see I'm not the only one that has trouble transitioning from playing with Rebol to actually using it in non-trivial programs. Sure they have a form of OO, but I'm not sure if it is really idiomatic to use it a bunch or if coding should be more like C. I'm prepared for Red zealotry though if they can provide the experience that they're aiming for along with good doc.


If there's any issue in particular you're having with Rebol then do pop by to either...

* chat - https://chat.stackoverflow.com/rooms/291/rebol

* forum - https://forum.rebol.info/

... and we'll do our best to help.


Thank you for all the help and kindness.


Red is not dogmatic about objects, but there is certainly a clear line between idiomatic Red and other code, in a more general sense. That is, you can use objects, or not, and write idiomatic Red. It's all in how you use them. They are most useful in terms of creating namespaces (contexts). When you don't need that, blocks are the more common type to use. There is also a `map!` type, which is a useful type because it has a literal form, like blocks. Of the 3 (block, object, map), only blocks are directly parseable, but objects and maps support reflection.


Thanks again. As a beginner in this language family it would be helpful to see the doc go over this with some examples clarifying your points at some point when y'all are closer to 1.0. I'm probably not the only one who wouldn't know how to architect their code without overusing classes.


Have a look at "Rebol - A Progammer's Guide" by Olivier Auverlot & Peter Wood, which an e-book version (PDF) is downloadable for free: http://www.lulu.com/gb/en/shop/olivier-auverlot-and-peter-wi...

In the book it covers creating a FTP dialect. Also there's a brief bit on creating a terminal cursor dialect.

NB. Book is for Rebol 2. There are improvements to parse in Rebol 3 & Red but the books dialects examples should still work as-is.


Not a full blown reference, by any means, but http://www.red-lang.org/2013/11/041-introducing-parse.html does contain a lot of Red's `parse` details in a short space, which may be helpful.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: