HNHacker News
TopNewBestAskShowJobs

greggirwin

164 karma · joined May 23, 2015

submissionscomments
greggirwin··on Ren: a lightweight data-exchange text format
Unknown is a nice word for this, yes. And while we don't focus exclusively on being terse in the Redbol world, "unknown" is a lot more work to type than "none", harder to scan visually as well.
greggirwin··on Ren: a lightweight data-exchange text format
Which Rebol fills this space, R2 or R3? The idea was also not loadable Redbol compatibility (which would be nice of course), but general utility. So Ren adds new types and changes others, where it thinks that is best.
greggirwin··on Ren: a lightweight data-exchange text format
We can throw out options for a long time, as there is no perfect choice. Ren went with `none` as it is standard Rebol and Rebol's designer thought about it long and hard.
greggirwin··on Ren: a lightweight data-exchange text format
Some similarities, but different in that EDN has a tagging approach for some types, and a more limited set of literal value formats.
greggirwin··on Ren: a lightweight data-exchange text format
Apologies for that. A lot were just for fun/future ideas. Many links to existing resources on other formats do work.
greggirwin··on Ren: a lightweight data-exchange text format
Thanks for the input. The idiograms were found based on the Ren name and meaning, but I'm not a native Chinese speaker, so will defer to those who know, and make things clear.
greggirwin··on Ren: a lightweight data-exchange text format
What do you suggest? ¤ is really the only other option, but $ seems much more universal, if you can choose only one.
greggirwin··on Ren: a lightweight data-exchange text format
Not so. From the TOML page: "TOML aims to be a minimal configuration file format."

Ren is intended to be a general purpose data exchange format.

greggirwin··on Ren: a lightweight data-exchange text format
Noted. Thanks.
greggirwin··on Ren: a lightweight data-exchange text format
Author of the Ren page being discussed here. Didn't expect to see it on HN. :^)

The Ren site (ren-data.org) redirects there, is quite old now, and was a playground and experimental area. Hence the empty links and such.

In addition to Bolek's Humanistic repo, I had set up https://github.com/Ren-data/Ren to discuss ideas. Ren is, effectively, Redbol (Red+Rebol). One of the initial goals was to define a subset of values and normalize the syntax (Rebol never formalized its format spec), which could be shared across Redbol langs as they evolved and went in different directions. And also as a bridge for loaders in other languages. JSON has taught us that a small spec is important. The balance between simplicity and expressive value types is key.

It may come back to life at some point, but my time was better spent elsewhere for a while. I'm focused on Red now (red-lang.org). It has a native bridge feature for embedding in other langs (https://doc.red-lang.org/en/libred.html), along with a lot more. I believe there is still value in formalizing the grammar so others can create their own implementations, but it's not a priority at this time. In the meantime, you can find the active Red community at https://gitter.im/red/red to get more information and examples of what it looks like in use.

Cheers.

greggirwin··on Red Programming Language 0.6.3
The main one was that having a single language was a win, compared to mixing 6 or 7 of them, and their associated cognitive overhead. Red expands this in both directions, with Red/System as the low level dialect and metaprogramming at the highest level.
greggirwin··on Red Programming Language 0.6.3
Still, https://doc.red-lang.org/en/ has some nice docs, and more are in the works.
greggirwin··on Red Programming Language 0.6.3
Making it prominent will appeal to a different target audience. Rebol is beginner friendly, but dialects (as easy as it makes them) are an advanced topic. We'll try to provide good docs and examples for Red, though, because it is a key feature that sets it apart.
greggirwin··on Red Programming Language 0.6.3
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.
greggirwin··on Red Programming Language 0.6.3
Rebol/Red (a.k.a. Redbol) languages inherit from Lisp, Forth, and Logo, along with Self for the object model. Tcl was not an influence as far as I know. There will certainly be other minor influences, as Sassenrath, Ousterhout, and Cowlishaw were all important designers in that era.
greggirwin··on Red Programming Language 0.6.3
This is certainly how I am sometimes. I will stop to check things, but it breaks the flow. And, as comments here point out, docs are a big issue. What isn't always clear is how much effort they take to create. With a small team, it's a constant struggle for where to allocate resources. Right now, Red's priorities are based on deliverable functionality.
greggirwin··on Red Programming Language 0.6.3
Indeed, Curl had a number of common goals with Rebol. Good insight.
greggirwin··on Red Programming Language 0.6.3
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.
greggirwin··on Red Programming Language 0.6.3
Yes, absolutely. Red has a `parse` function, that uses EBNF-like rules, but someone has written a nice regex translator if you need that bit. It's also possible to write a nice AWK-like dialect that handles things at a higher level. I've done that in the past. One of the current limitations is that the I/O model is simple, and there is no GC yet. Those will come in the relatively near future, but if you have large files, or need long running processes, it will be more work for a while. Still doable, just not as easy.
greggirwin··on Red programming language 0.6.2: LibRed and Macros
Yeah. It hasn't been pressed much yet, since it's new to a lot of us. Here's something I worked on to learn more about it: https://gist.github.com/greggirwin/38883ca5109175a60896d2f40...
greggirwin··on Red programming language 0.6.2: LibRed and Macros
Got it. Red does manage memory for you, but no GC yet so can't do long-running procs without care. I've written small Red apps that used 800MB, loading a large dataset. Totally stable but, again, maybe wait for GC if you're going to grind a lot.

Red's complete toolchain, compiler, linker, etc. are bootstrapped entirely in Rebol2. Red is more capable than R2 (though alpha, with features pending), so it's safe to expect that it can handle more than simple cases. In fact, one of the reasons Red 1 was implemented in R2 was to prove that Red would be able to self host. It's possible most of the current toolchain would even work at 1.0, but the team has learned a lot while building this version, and has said on many occasions that Red 2 will only keep the best bits.

All that said, even if you never use it in production, it's a great language to play with and expand your thinking, because it's so different.

greggirwin··on Red programming language 0.6.2: LibRed and Macros
Red will have GC, but it's not there yet. Soon. Red/System is a C level language, where you have to alloc/free yourself.

Why do you think it's pointless to learn without knowing how it handles memory?

greggirwin··on Red programming language 0.6.2: LibRed and Macros
Yup. We often write code like normal programmers, but sometimes we do build up vocabularies more, even when not using `parse` to write DSLs.

"Red or REBOL" = Redbol (sounds like Red Bull) :) And where Perl has Mongers, Ruby has Rubyists, Python has Pythonistas, and Rebol has Rebolers, Red has Reducers.

greggirwin··on Red programming language 0.6.2: LibRed and Macros
We, as programmers, will never convince anyone that our preferences are right for everyone else, even when there are strong technical arguments. In this case (pun intended), it's subjective. A lot of it is what we get used to.
greggirwin··on Red programming language 0.6.2: LibRed and Macros
Thanks for the clarification. Still not compatible with Red's licensing model IMO.
greggirwin··on Red programming language 0.6.2: LibRed and Macros
It has an FFI, but no static linking to C libs at this time. Not sure if that will come, but technically it's possible, as Red's linker is written in Red/System. I'm a huge fan of Pieter Hintjens' work, and have written lots of code generators and FSM stuff, inspired by GSL and Libero.
greggirwin··on Red programming language 0.6.2: LibRed and Macros
One of the nice things about Red is the low barrier of entry, for experimenting and getting a taste. If you can drop an EXE somewhere, you can run it and try things. If you can run "red -c ..." you can compile and include Red/System code.
greggirwin··on Red programming language 0.6.2: LibRed and Macros
That is exactly its goal.
greggirwin··on Red programming language 0.6.2: LibRed and Macros
> 1. Any reason for not wanting to target WebAssembly/JavaScript (and in conjunction node.js [I understand that this isn't trivial])?

Wasm will likely be the browser target.

> 2. Any reason targeting QT isn't on the roadmap? [targets for KDE, Sailfish, ect..]

They wanted to go native to start. QT is GPL licensed. Not a good fit for Red. Their "small" installer, which downloads the big stuff, is 18M. Red, with self-contained toolchain and cross compiler + GUI, is 1MB.

> 3. Any reason wxWidgets wasn't a great choice as a foundation? (I believe they have a C API last I looked)

Targeted at C++, and also very large.

> 4. Is there or will there be an API for creating custom languages that can target/leverage Red's infrastructure? (basically a Red version/wrapper for flex/bison)

You can use libRed, which makes Red available as a DLL you can call into from other langs, like C. See http://www.red-lang.org/ where a couple GIFs show integration with VBA and Excel even.

Ultimately, the decision not to use something comes from value added and available resources. Team Red is small, and has to pick their battles carefully.

greggirwin··on Red programming language 0.6.2: LibRed and Macros
Per Nick's comment, above, Red likely won't generate C, because that would add a dependency on a C toolchain. Red is completely self-contained, and would like to stay that way. However, you could write those tight bits in C and put them in a DLL or something, to call from Red.
← PreviousPage 4 of 5Next →