Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
draegtun
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
1.
▲
by
draegtun
3mo ago
The article doesn't mention Perl at all but it did have some direct influences on Ruby. Even Ruby's trailing blocks syntax are an homage to Perl's block list subroutines: # first Ruby example in article users.select {
2.
▲
by
draegtun
9mo ago
Yes (de)referencing can be a PITA sometimes but you've probably forgotten that your example code could have been better written like this: $hash1->{key1}{key2} And if `hash1` was a hash (instead of a hashref) then it's
3.
▲
by
draegtun
1y ago
Or in Red's case, Parse - https://www.red-lang.org/2013/11/041-introducing-parse.html
4.
▲
by
draegtun
1y ago
Except in homoiconic languages, like Rebol/Red/Lisp, there is no (need for a) new syntax.
5.
▲
by
draegtun
1y ago
Or in Rebol/Red it's Parse , a dialect (DSL) that comes with the language - https://www.rebol.com/docs/core23/rebolcore-15.html
6.
▲
by
draegtun
2y ago
You can do this in... # perl my $x = do { … 5 }; ;; Rebol/Red x: do [ … 5 ]
7.
▲
by
draegtun
2y ago
Everything is subjective of course :) I remember comparing Tcl/Tk with Rebol/View - https://news.ycombinator.com/item?id=7069311
8.
▲
by
draegtun
2y ago
Hopefully these two links will help: - Definitional Scoping / Rebol actually does not have scoping at all - https://stackoverflow.com/q/21964110/12195 - Bindology - https://en.wikibooks.org/
9.
▲
by
draegtun
2y ago
>> I think Cale is an underrated vocalist I totally agree and more so on ballards. The hairs on my back of my neck always stand up when I hear I Keep A Close Watch (especially the M:FANS version [1], but the original Helen of Tro
10.
▲
by
draegtun
2y ago
To add to this "A Date with Perl" by David Rolsky (video below is from 2017 but he has same talk going back 10+ years). https://youtu.be/enr5_FoToiA
11.
▲
by
draegtun
3y ago
>> It really should be a few lines of code to add an “unless(X) {}” statement to “if(!X) ()” to... Or even one line :) Factor... : unless ( ? quot -- res ) swap [ drop ] [ call ] if ; inline Rebol/Red... unless: func [
12.
▲
by
draegtun
3y ago
Here's a video where Crockford mentions Rebol (and others) being an influence on JSON - https://www.youtube.com/watch?v=-C-JoyNuQJs&t=1233s I've seen it mentioned on Rebol chatter that Crockford approached Car
13.
▲
by
draegtun
3y ago
It's worth looking at Rebol [1], a language that is also homoiconic which was influenced by Lisp, Forth, Self & Logo and had a big influence on JSON too! user: [name: "John Doe" birth-date: 1970-01-01 account-balance:
14.
▲
by
draegtun
3y ago
And Sakamoto would end up being involved in some of those Sylvian solo records. A fly on the wall video of the 1st album [1] recording sessions was posted couple of years ago [2] which includes bits where you can see Sylvian/Sakamoto w
15.
▲
by
draegtun
4y ago
>> People pretends Smalltalk doesn't exist? And Factor and many implementations of Lisp too!
16.
▲
by
draegtun
4y ago
Arturo was influenced by Rebol which comes with LOOP - http://www.rebol.com/r3/docs/functions/loop.html However there are some differences... loop 10 [ print "hello" ;; prints "hell
17.
▲
by
draegtun
4y ago
David Sylvian & Holger Czukay produced two wonderful ambient albums together in the 80s... Plight & Premonition - https://en.wikipedia.org/wiki/Plight_%26_Premonition Flux + Mutability - https://
18.
▲
by
draegtun
4y ago
Yes they used to be called Associative Arrays. I think the change occurred between Perl4 & Perl5. In Programming Perl it says "Associative Arrays" in 1st edition and "Hashes (Associative Arrays)" in 2nd edition. NB
19.
▲
by
draegtun
4y ago
Tcl would be a good choice here - https://www.tcl.tk/man/tcl8.5/tutorial/Tcl26.html
20.
▲
by
draegtun
4y ago
Also see "Ostrich" tuning used by Lou Reed / The Velvet Underground - https://en.wikipedia.org/wiki/Ostrich_guitar
21.
▲
by
draegtun
4y ago
The REPL s that come with Lisp, Smalltalk & Factor are in a different league. There's probably a few different reasons to why but one thing that the 3 i've listed above all have in common is that they have image-based environ
22.
▲
by
draegtun
4y ago
Well if we're creating a list then I would also add Factor, which provides a full graphical REPL with code browsing, help/docs system, step-thru & interactive debugger, full data/state inspection and much more.
23.
▲
by
draegtun
4y ago
Perl has dynamic scoping (along with lexical scoping).
24.
▲
by
draegtun
4y ago
And Rebol. Arguments sent as `[blocks]` are always unevaluated but you can also explictly set a function argument to not be evaluated... f: func ['a] [ print ["you gave me: " a] print ["and this is
25.
▲
by
draegtun
4y ago
Also have a look at PARSE in Rebol & Red - http://www.rebol.com/docs/core23/rebolcore-15.html This is how your example would look like in PARSE rule... 1 3 [{What is your } ["name" | "quest&
26.
▲
by
draegtun
4y ago
Also same for Rebol & Red. And its easy to view the source code from the console (REPL). Some examples from Rebol2... >> source func func: func [ "Defines a user function with given spec and body."
27.
▲
by
draegtun
4y ago
>> It's yet another poor re-implementation of S-expressions and Lisp. Or alternatively Rebol, which was one of the inspirations to JSON. With Rebol you could write these patches like this: patch [ replace /ba
28.
▲
by
draegtun
4y ago
Perl does have lambdas... my $double = sub {$_[0] * 2}; $double->(5);
29.
▲
by
draegtun
5y ago
I like using `parse` in Rebol / Red - http://www.rebol.com/r3/docs/functions/parse.html Here's the parse rule for Batman: [ 16 "na" 2 [space "batman"] ] And
30.
▲
by
draegtun
5y ago
> This unique feature of Ruby has been leveraged by DHH back when he created Ruby on Rails framework This isn't unique to Ruby and is possible in other languages. For eg. in Smalltalk you could create this DSL ... 1 day ago.
More ›