« first day (1581 days earlier)      last day (2199 days later) » 

3:06 AM
@rgchris I think the argument about trying to serve Ren situations in which the only things you'd have as JSON parallels are BLOCK! and MAP! makes a fairly strong case for either #(...) or @(...) to help make the difference more obvious from [...].
For construction syntax, I do think that moving the type outside is a very good idea. function@[[...][...]] vs. @[function! [...][...]]
@RebolBot
x: make map! [foo: 10 bar: "hello"]
print x/foo
print x/bar
@rgchris the real case against #(...) comes from what I've been saying about the space significance rules of legitimate Rebol tokens abutting parentheses or blocks. If # can validly stand alone to mean a NONE! value, then having it uniquely "stick" to parentheses is bad. This is why I suggested @(...) be a syntax for making maps, and #(...) load as equivalent to # (...)
And I do believe that there is a need for a literal NONE! value, and like a lone # for that.
It will be necessary in Ren, for instance. Because the maps don't evaluate, the only way to get a real NONE! will be with a literal form.
Of course, this points to a greater issue, that all things you use in a map will not be evaluated. :-(
So really it should probably be the case that @(...) is not a literal map, but rather a literal OBJECT!, to be more in alignment with the properties of JSON. It's studied by structure usually, unless you execute it in a Ren-runtime-aware environment, in which case it will load as an object.
 
0
Q: String searching in Rebol or Red

gnatWhile this is a real question, and one which I think applies to red as well as r2, I will confess I wouldn't mind 20 points, either. I'm interested in search/replace operations on strings, with a mind to try to hack out a sed-like utility in rebol as a learning exercise, at least. So I imagine ...

 
4:16 AM
Welcome @gnat ... I edited your question to be a little less "enthusiastic". StackOverflow Q&A has kind of a "just the facts" attitude.
(Briefer the better, usually... people are always editing out "Hi, I have a question and was wondering if you could help" and "Thanks for any advice, Sincerely Joe Q. Questioner" to try and make it so the question has less vertical scroll space)
 
0
A: String searching in Rebol or Red

HostileFork I was told I should have done this: >> if found? find STR "z" [pos: index? find STR "z"] == 18 >> if found? find STR "n" [pos: index? find STR "n"] == none >> pos == 18 Really? I have to search the string TWICE; the first time just to be sure it is "safe" to search AGAIN? You certa...

 
So hey, folks (@kealist, @Adrian, @WiseGenius, others) perhaps give @gnat the "Rebol bump" to 4 upvotes for the chat privilege.
 
2 to go.
 
4:38 AM
So given the Ren argumentation for JSON equivalency and ergonomics I've been making, @(...) has to be the literal object! syntax. But people are speaking about wanting a literal map, and map@[...] is apparently not good enough. I'm not sure exactly why that isn't good enough, if it weren't used in Ren exchange situations.
To my eyes, the value of # as a literal NONE! exceeds the value of #(...) or #[...] breaking the spacing rules to create this other form. And @[...] being map while @(...) being object just seems to subtle a distinction to absorb.
@earl I know you're one of the people pushing for the literal map, but what did you think of my Ren-to-JSON apples-to-apples comparison point of needing it to be an OBJECT! so it can behave as expected? (TRUE not ending up a WORD! in a map, but a logic value, for instance).
 
@HostileFork Done
 
A literal object notation seems pretty handy, and would help get rid of the OBJECT word. So you could write: object: @(x: 10 y: "Hello") It's more limited than MAKE OBJECT! because you can't COMPOSE it.
@gnat Okay, 1 more...
 
4:56 AM
@gnat Okay, you're set (assuming no angry passer-by downvotes you)! First time's free, but you'll have to work hard on your questions. :-) It takes a while for reputation balances to move from the site to the chat server.
 
@HostileFork Or 0. My vote apparently didn't take the first time. My internet's really bad ATM.
 
@gnat To keep from running afoul of the SO police: be sure to read the Help Center topics on What's on Topic?, What Questions Should I avoid Asking, etc. etc. Another important one is Minimal, Complete, Verifiable Example. Your example showed code for finding things in a string, but it didn't provide the string...for instance (I added a not-creative one).
@gnat And pick a profile picture to help us identify you: How to set your profile pic
 
@HostileFork Couldn't this same argument be made against #{...} for binary?
>> [4{four}]
 
@WiseGenius It could if I weren't arguing that the rules for spacing involving () and [] not apply to string and tag, which I am arguing the benefits of abc{def}ghi being the same as abc {def} ghi are not interesting, and in fact chew out large amounts of potentially useful lexical space for what would only be ugly code.
[] and () must at least be able to have no space requirements on their internals, and people are used to it not requiring spacing on the externals too.
I think the argument of "" and <> and {} needing the same is not strong, and also not even true today, as pointed out with # being a none!
The poor sufferer in this crossfire is Rebmu. :-/ But Rebmu is willing to take one for the team.
And actually, with my newfound belief that printing words is a feature and not a bug, and with space escaping in words, there are new ways to tackle it.
>> print ['Hello 'World]
@johnk Just in time. :-)
In any case, Rebmu will have other options for how to compete that won't require strings to need to be allowed to jam up against other characters.
*(We all know that Rebmu is of course the ultimate goal of the Rebol and Red projects. We're going to fit replication into the database that fits into a QR code if it's the last thing we do. And at least another level or two into the very-tiny-Angry-Birds clone.)
 
5:12 AM
@HostileFork What if some other character were used for a none! value instead of #, and keep # for all the other things it would be used for (binary, construction, map, etc.)?
 
@WiseGenius Possible. But I don't know what that character would be, and I happen to like #. The reason it became a NONE! was because ISSUE! turned into a WORD!, and there was a desire to avoid empty-named words.
And # is fairly heavily overloaded as it is. I think there's already too much leaning on it to use it for construction syntax. And datatype#[...] doesn't speak to me as well as datatype@[...] does
So freeing up #[...] and #(...) to mean the same as # [...] and # (...) with # as a NONE! literal seems a fine plan to me. Consider #X[...] and #X(...) become #X [...] and #X (...)
 
@HostileFork Yes, I like the look of datatype@[...] too.
 
It remains to be seen if the proposal to allow @FOO ever comes to fruition. There hasn't been a lot of movement on that. It could be useful, but so could a lot of things, and that discussion came before this construction syntax consideration.
If that did exist, it would make the argument vs. # less compelling.
But I believe that if @ gets taken for construction syntax we should probably ease off pushing that proposal, which people haven't really been championing
That way an email will generally really look like an email. There won't be much confusion about joe@example.com(...) or joe@example.com[...] being mistaken for a construction syntax.
 
@RebolBot alive?
Oh dear :-/
Just resting I'm sure. I'll be back soon to fix her
 
5:42 AM
@HostileFork Just trying to follow what's currently on the table. Is this a fair summary?:

# none!
#... issue!
#{...} binary!
@[...] map!
@(...) object!
@{...} word!
foo@[...] foo! (construction syntax)
 
@WiseGenius The two of those I'm not so sure about would be @[...] and @{...}, especially the former. Because I think the @[...] and @(...) is very subtle to see, and object and map are very similar yet different.
So I'd pare down the "here's what I think" to:

# none!
#... issue!
#"..." char!
#{...} binary!
@(...) object!
foo@[...] foo! (construction syntax)
map@[...] map! (for instance...)
 
@HostileFork What happened to @{...}? I see it being even more subtle to differentiate from @(...), but what's your rationale for skipping it?
 
@WiseGenius Well, I used to think it was important and was pushing for analogs to oddities like :@{get word with spaces} or @{set word with spaces}: but I think there's no need to make it any more complicated than it needs to be with the caret escaping proposal.
Making words with spaces in them "prettier" isn't necessarily in the best interest of the system.
word^_with^_spaces is fine; no need to complicate the syntax with more exceptions
They are to be discouraged, not encouraged...and should appear only when external dependencies force them in the dialect.
In any case, the union of these proposals is starting to feel (strangely enough to say) like actual progress on longstanding issues.
 
6:02 AM
How about?:

\ none!
#... issue!
#"..." char!
#{...} binary!
#[...] map!
@(...) object!
foo@[...] foo! (construction syntax)
Or:

# none!
\[...] map!
I suppose my bias for #[...] for map! is that ́# is like a hash.
...and that my bias for having something short for map! is that I use it so much.
Also, @DocKimbel apparently sees a literal notation for map important enough to consider changing construction syntax from #[...] to #(...) just to accomodate it, so it's map that's initiating the possible change in the first place. That's why I think if we are going to have a proposal for foo@[...] for construction taken seriously by him at this time, we should also have something for map.
*at this apparently critical time
 
6:36 AM
@WiseGenius Well if a literal none is done another way, for instance even none@ isn't that bad... then perhaps.
Or for that matter, perhaps just @
 
@HostileFork I was thinking that before.
 
foreach @ [a b c] [print "No loop variable"]
It's not horrible. "Construct...NOTHING!" Which was the previous line of thinking
 
But then what for object?
 
@(...)
Oh, I see
Right, the argument from before.
Well... bah. none@ isn't the end of the world for literal none. It's not as bad as #[none!]
I don't care for \
I guess I was having trouble anyway with the idea of the canonization in the console. What would if 1 > 2 [print "math fail"] mold out to, if it had a choice? Before would it have chosen # or #[none!]? If there's only one way to say it, and it's legible, that's all right I guess.
none@ can work for me I guess for literal none.
#... issue!
#"..." char!
#{...} binary!
#[...] map!
@(...) object!
none@ none! (construction syntax)
unset@ unset! (construction syntax)
any-word-or-string@{...} (construction syntax for words, strings)
structural-type@[...] (construction syntax for structural types, variable block format)
@WiseGenius Are we getting closer?
 
@HostileFork How about something double for none, like ##, @@, #@ or some such?
I suppose it starts to get too cryptic when you look for something for unset!, but then I don't know if that's used very much?
 
6:45 AM
>> type? ##
Invisible RebolBot says "issue!"
 
** Syntax error: invalid "issue" -- "##"
** Near: (line 1) type? ##
 
I don't know about allowing # in words unless you use some escaping or construction syntax
Oh, that was a Rebol2 console I had up
Okay, well of the options you list ## seems like the one I'd like most
The reason I think it'd be good to use something foreign is because I just know if that's not what people use, they're going to screw up and instead of writing foreach none@ [a b c] [print "No loop variable"] even someone who knows what they're doing is going to slip and write foreach none [a b c] [print "No loop variable"] and not notice until the cryptic bugs happen later
So better to train people to think of a literal none as something that doesn't have the word "none" in it. It's more about that than about saving typing.
 
.
 
## none!
#... issue!
#"..." char!
#{...} binary!
#[...] map!
@(...) object!
none@ none! (alternate via construction syntax)
unset@ unset! (construction syntax)
any-word-or-string@{...} (construction syntax for words, strings)
structural-type@[...] (construction syntax for structural types, variable block format)
 
@HostileFork Sure.
 
6:53 AM
Well that's the least broken spec we've seen yet, I think. Can it get better?
The rounding of @(...) almost says O in Object.
 
@HostileFork What's the reason for the alternative none@?
 
red> "Alive?"
 
; Brought to you by: try.rebol.nl
== "Alive?"
 
Would that be none@[]?
 
@WiseGenius It might not be needed. Perhaps the value of a canon form is more value than having it.
 
6:56 AM
@RebolBot alive?
 
:-)
ttyl
 
@WiseGenius I feel that set-word@{Some arbitrary word} is a better construction syntax than set-word@[{Some arbitrary word}] for instance. This is my thought, and it means that forcing the brackets is not going to happen in all cases... so why need it for unset@ and none@ (if none isn't going to just sidestep construction syntax altogether?)
The simple fact is that construction syntax is irregular once you get into the brackets. So why put the brackets in if you don't need them?
@johnk Yay. :-)
It might make it easier to pattern recognize construction syntax things with a string processor if they all said type@[...]. But you're not supposed to have to do that. LOAD does it. It can do it once and just do it right.
 
@HostileFork Righto.
 
I don't think it would be a problem if MOLD chose to output a literal NONE as ##
That seems a decent enough canon form.
MOLD should be opportunistic. If it can do it pretty, it does. If it can't, construction is a fallback.
It already makes judgments about whether to do strings with quotes or braces.
>> {string}
 
7:04 AM
; Brought to you by: try.rebol.nl
== "string"
 
>> {"string"}
 
; Brought to you by: try.rebol.nl
== {"string"}
 
So if you said >> none you would get back == ##
Though you say >> true you would get back == true@, unless someone has a better idea for literal true shorthand. #T and #F ?
Oh, those are issues.
##T and ##F? :-)
I do not think passing literal true and false are as interesting a case in quoted contexts as a literal none is.
 
@HostileFork True.
 
@WiseGenius This is a critical time. And a critical time to be making reasoned arguments about this stuff.
I do not think construction syntax (which I apparently named) ever really got canonized into the documentation on any wide scale, and given that the console never accurately output it...the casual user doesn't know it exists.
>> none
 
7:14 AM
; Brought to you by: try.rebol.nl
== none
 
As that's all many have seen (and scratched their head over...) it's not an earth-shaking thing to change it.
I don't think hardly anyone knew about the # as a NONE!
So really, what we're talking about here is about firming up something that was never actually put through any real design review. This is that moment.
And with the caret escaping thrown in, I think this is the chance to make Ren viable as the superior superset of JSON it needs to be.
 
7:32 AM
{"menu": {
  "id": "file",
  "value": "File",
  "popup": {
    "menuitem": [
      {"value": "New", "onclick": "CreateNewDoc()"},
      {"value": "Open", "onclick": "OpenDoc()"},
      {"value": "Close", "onclick": "CloseDoc()"}
    ]
  }
}}
There's a sample from json.org.
@(menu: @(
  id: "file"
  value: "File"
  popup: @(
    menuitem: [
      @(value: "New" onclick: "CreateNewDoc()")
      @(value: "Open" onclick: "OpenDoc()")
      @(value: "Close" onclick: "CloseDoc()")
    ]
  )
))
And that's not one that works in Ren's favor in particular, compared to other examples. No strings with quotes in them forcing escaping, lots of objects so lots of @. Despite the lack of obvious advantage, I think it's still marginally better.
Note the ability to escape characters in set-words with ^_ is crucial.
 
hi can i ask question here? :o
 
@HostileFork Agreed. What about mold/all? Am I correct in thinking mold/all none should return ## rather than none@ and mold/all map [...] should return #[...] rather than map@[...], etc.
 
@UserBlanko Hello! If it's about Rebol and Red, most certainly. If it's about something else, perhaps we can direct you elsewhere. What do you need?
 
@UserBlanko Welcome!
 
erm i need help on understanding software developement
the other chat room are quite dead i guess
thanks :)
 
7:38 AM
@WiseGenius Well, that's the theory I'm putting forth here. If you save a block and it's reduce [none none none] would you rather see that saved out to disk as [none@ none@ none@] or [## ## ##]? I guess it's a matter of taste.
@UserBlanko That is what we would call a "broad topic". What kind of software development are you interested in?
 
ahh i guess it would be just basic understanding especially baseline. I understand baseline is to control changes made to the system or documents but how does it provide integrity ? integrity meaning is whole and undivided
 
@UserBlanko Hm. What is your native spoken language?
 
english? i guess
 
Hm. Unusual sentence constructions there.
 
actually is broken english
yes, singlish perhaps you might heard of it.
 
7:42 AM
Hmmm. Well if I really wanted someone to understand software development I have a favorite thing myself... but it's just personal for the parts of software development I find most interesting.
I will give it to you as a suggestion, it is a game
 
There are actually many parts to software development i guess? The process itself have many models, like waterfall, prototyping and agile methods like scrum
 
@UserBlanko That's more the software development process. Kind of what managers worry about more than engineers. We are engineers here, mostly. So we are interested in the nuts-and-bolts and mechanics of the machinery.
Which if you ask me, is the more fun part.
 
Oh i get it so to develop a system there are two parts software development process and software engineering process?
 
@UserBlanko Probably more parts than that. But on StackOverflow, most of the people will be talking about the engineering side. People talk about process more on programmers.stackexchange.com.
 
oh thanks @HostileFork but what are the differences ?
 
7:49 AM
>> foreach thing ["olleH" "erehT" "oknalBresU@"] [print reverse thing]
 
; Brought to you by: try.rebol.nl
Hello
There
@UserBlanko
 
hi @RebolBot
 
@UserBlanko Programming is about making machines. Process is about making sure you are keeping the team building the machines in proper line so that they don't make disruptive changes and stay on schedule. In process you come up with ideas like making everyone work in pairs so no one ever does something without another person to catch their mistakes...then you see if that makes things better, or just cuts the project speed in half by being redundant.
Here we talk about making machines, and complain about how slowly it happens, because there are no managers to enforce a process. :-) It is what happens on open source projects developed on the Internet by volunteers, people just work on what interests them.
@UserBlanko I'd suggest for general chat about "what is programming and process" you might try: chat.stackexchange.com/rooms/21/the-whiteboard
 
alright thanks for your help @HostileFork i try to digest this bit first
 
Here we specifically talk about two languages: Rebol and Red. They can be accessible to learn, but they are works-in-progress. They are not well known yet.
 
7:58 AM
@HostileFork Good. I think agree then. mold/all doesn't have to use construction syntax just for the sake of it if it isn't necessary.
>> mold/all #[block! [#[string! {Hello, World!}] #[binary! {Hello, World!}]]]
 
; Brought to you by: try.rebol.nl
== {["Hello, World!" #{48656C6C6F2C20576F726C6421}]}
 
@WiseGenius Also, I do not believe in a non-all version of MOLD
Anything you MOLD out, you can LOAD in.
And I also am still racking my brain for a better name than moldy-old code...
TO-REN is not bad.
But SAVE seems a better parallel, perhaps obviously
 
@HostileFork I was just about to say the same thing.
 
However you need some way to write to a file without going through an intermediate string. So SAVE/TO ?
SAVE would thus function as MOLD/ALL, and then SAVE/SOMEREFINEMENT would add the place you want to save to to avoid intermediate storage
I recall people throwing a fit when I tried to institute the SAVE change before and I don't remember why.
 
@HostileFork I'm not sure what you mean. Can you give an example? I've probably missed a discussion or two, too.
 
8:10 AM
>> help save
 
; Brought to you by: try.rebol.nl
USAGE:
    SAVE where value /header header-data /all /length /compress method

DESCRIPTION:
    Saves a value, block, or other data to a file, URL, binary, or string.
    SAVE is a function value.

ARGUMENTS:
    where -- Where to save (suffix determines encoding) (file! url! binary! string! none!)
    value -- Value(s) to save

REFINEMENTS:
    /header -- Provide a REBOL header block (or output non-code datatypes)
        header-data -- Header block, object, or TRUE (header is in value) (block! object! logic!)
 
Just the concept of trying to make SAVE into a single-arity parallel for LOAD would be a bit of a tricky transformation. All the functionality needs to go somewhere. It's hard to push it all around and worry about generating large intermediate values.
Put in other words: because MOLD exists, SAVE's mission is completely different.
@UserBlanko I haven't published a lot of writing for new programmers, but maybe these notes will interest you: blog.hostilefork.com/why-php-is-mind-poison
 
8:39 AM
thanks @HostileFork but isn't like the basic to programming ? Like if we want to have our own programming language we have to consider these points?
 
@UserBlanko When picking languages you have to consider many things. Some people when going to learn will look at the job sites, look at the salaries, look how many jobs there are. If the money is high and there's lots of them... that is what they learn. It depends on why you are interested in programming. Is it an art form or a creative pursuit, or is it a means to an end? Which is it for you?
I work on art here for Rebol and Red, it's a creative project. I think we have some of the best language icons around. :-)
Personal opinion. ;-)
And we agonize over the details, which people have been agonizing over for decades now.
Whereas JavaScript was designed in 10 days. They admit that's all the time they spent on it.
 
My teacher always say once you learn programming it is the same for all the languages is just the syntax difference.
For me personally I have no qualms about which language to learn, I just learn whatever I need to I feel taking on low level language like C might help understanding more on the higher level languages like java. I guess I pursue what I like then.
@HostileFork how long have you been programming?
 
8:57 AM
@UserBlanko Perhaps your teacher simply means that once you learn programming it's easier to learn other programming languages?
I would argue that compared to others, syntax is often one of the more superficial differences between programming languages.
 
i guess so
no wonder because i just started 2 years only in school and not really doing a good job , result-wise are not bad but comes to programming it's a different story
I find it hard to learn concepts
So far for 2 years I been learning java, j2ee , Swing but really did not master any of them I guess is a form of touch and go.
 
@UserBlanko I do not think those are "fun" programming environments, and no one uses Swing. So you are learning something pointless with that.
@UserBlanko I hope you will follow my advice, and try SpaceChem. It's a fun way to sort of begin to understand the whole of issues in programming, as a game. Really it covers so many issues... threading, processes, latency, message queuing...
@UserBlanko Have you seen Karate Kid, where the master says he'll teach him and he makes him do various chores... wax the car, sand the floor, paint the fence... ? :-)
 
Yea I did is kind of exercise which would help him right?
@HostileFork isn't SpaceChem a game on steam?
 
@UserBlanko Yes. And I promise you, if you play through SpaceChem, and understand the game, you will understand programming. :-) There is a free demo, full game costs nearly nothing for how great it is.
$9.99 is it?
If you play through the free demo and solve all the levels up to the end, and show me a video of you playing it, I'll paypal you the cost.
 
9:13 AM
@HostileFork it's alright I take a look at it during the holidays, exams in 3 days x.x
 
@UserBlanko It is sad to think of someone believing programming is "J2EE and Swing". It's a very sad picture. It is like what this math teacher wrote: A Mathematician's Lament. It is a very good essay, and so true. In programming it is the same when you are put through such bad experiences as a first exposure.
 
@HostileFork haha my first experience with programming is java just making normal run on consoles programs, honestly it was so much fun
 
@UserBlanko Well when you just get to make things do whatever, people write all kinds of stuff, and it is fun. It's making a robot and watching it go. I liked programming in machine language ...my programs didn't do much, but that they worked at all was impressive in retrospect. I didn't know about compilers or assemblers. :-)
 
@HostileFork what do you do for a living?
 
9:29 AM
@UserBlanko I haven't seen SpaceChem before, but if HostileFork recommends it that much, it must be good! I think I'm going to play it now.
 
@UserBlanko I frame art. :-)
 
hahaha I want to too, but exams x.x Monday it would be on software engineering and on Tuesday it would be on operating system.
 
@WiseGenius Created by the guy who basically designed MineCraft... the precursor, called "InfiniMiner".
He had a day job at Microsoft and kind of prototyped it but lost interest, in particular because hackers were taking down his servers, and it was a hassle.
 
@HostileFork Haha!
 
@WiseGenius I'm quite good at it.
I have done it professionally
I just found an old picture of me getting my northeast division best framer award
Though, actually, that might be my "best Anthony Michael Hall impersonator" award. old JPEGs lose a lot of detail.
(For those curious what I looked like back in college. :-P)
@WiseGenius SpaceChem is the single most best engineering puzzle game I've ever played. Epic piece of work. So epic that I hope they don't just drop it, but keep working on the usability, there are a number of UI improvements that could be made.
I did a 3D model to help visualize what a reactor is like, never finished it
Blah, I should send that to Zach
But Sketchup is at its heart, a weak substitute for SolidWorks
I should have just bought a license, because working with toys is too frustrating
@WiseGenius Anyway, that model should help understand what's going on in the game a bit better than the flat picture conveys
 
9:44 AM
@HostileFork How so?
 
@WiseGenius Well, you can sort of see that on the bottom the pipes and which regions they feed into or out of, and that the middle is not connected to anything
 
@HostileFork you sure are old :x
 
@UserBlanko Yup! It gives me a right to be grumpy. You get a grumpy license, and a cane that you can hit kids with who annoy you...and they don't send you to jail.
 
@HostileFork you look quite good in college and the impression I am getting is an angry old gramp :x hahaha
 
@UserBlanko Older and grumpier by a factor of a million, for sure.
@UserBlanko From the Rebol/Red conference: huge beard now
 
9:49 AM
@HostileFork Ah, now I see. I had to reload the page to see that there was a second image and some other comments that my browser skipped. My internet connection has been bad all day. I have to hit “retry” on all my comments and by then they're usually late in the conversation.
@HostileFork Haha!
 
@HostileFork Are you the guy in a beard?
 
@UserBlanko Yup. Time ages us, doesn't it?
 
@HostileFork That beard is fake!! Anyway are those legit words in another language ?
 
@UserBlanko Rebmu is a real thing. Would you like to learn a small bit of Rebol? It is not like Java in any way shape or form.
@RebolBot
code: [print]
append code "Hello"
do code
 
; Brought to you by: try.rebol.nl
Hello
 
9:57 AM
@RebolBot
code:[print]
append code "hello word"
do code
 
; Brought to you by: try.rebol.nl
hello word
 
@RebolBot
code: ["Hello" print]
print ["The original code is" mold code]
reverse code
print ["After reversal, the code is" mold code]
print "Now we will run it..."
do code
 
; Brought to you by: try.rebol.nl
The original code is ["Hello" print]
After reversal, the code is [print "Hello"]
Now we will run it...
Hello
 
That gives you a slight impression that you're not dealing with a thing like Java
 
I have no idea what is that
wait let me guess
 
9:59 AM
@RebolBot
copy/part to-string read hostilefork.com 128
 
; Brought to you by: try.rebol.nl
== {<!doctype html>
<html lang=en>
<head>
^-<meta charset=utf-8>
^-<meta name="google-site-verification" content="eoQP3nJ2qyDceZYAYN6-}
 
There you see the first 128 characters from reading my website
 
woah so cool
 
@RebolBot
12-Dec-2012 + 30
 
; Brought to you by: try.rebol.nl
== 11-Jan-2013
 
10:00 AM
That's 30 days after the 12th of december 2012
 
let me try @RebolBot
copy/part to-string read http://chat.stackoverflow.com/rooms/291/rebol-and-red 128
 
RebolBot only responds to commands in which the @RebolBot is at the beginning, and only runs code if it's multi-line
 
I see
 
@RebolBot who is @hostilefork
 
@HostileFork I know this about hostilefork and their local time is 28-Feb-2015/5:01:40
 
10:01 AM
@RebolBot
who is @UserBlanko
 
; Brought to you by: try.rebol.nl
; rebol.com/r3/docs/errors/script-no-value.html
    *** ERROR
** Script error: who has no value
** Where:
** Near: try load/all join %/users/try-REBOL/data/ system/script/args...
 
When you did that as multiline, it ran it as code... not "RebolBot speak"
If you talk on the same line it speaks in RebolBot-ish :-)
22
Q: RebolBot - a chat bot for the chat rooms

Graham Chiu RebolBot is a chat bot with a natural English dialect interface, specifically targeting the StackOverflow chat rooms. Yet it has a modular design, can post tweets to Twitter, and could be modified with only a little effort to work with other chat systems. An instance of the bot hangs out...

 
you can post to twitter with it?!
 
It's only enabled if you are a chat room owner, so random people cannot post unless they are given authorization
 
@RebolBot who is @UserBlanko
 
10:03 AM
@UserBlanko Sorry, I don't know anything about UserBlanko yet. But ...
@UserBlanko I'd like to know about you! Use the 'save my details' command
 
@RebolBot save my details
 
@UserBlanko Can you elaborate on that?
 
Format is save my details url! [ timezone [ time! ] ] "saves your details with url +/- timezone"
 
Owhhh
 
So you say, e.g. save my details http://my.url and an optional timezone.
 
10:05 AM
I thought it automatically tracks your location and get the timezone
 
It has no way of knowing, I guess maybe it could look at your SO profile if you told it
 
@HostileFork is there other ways to contact you ?
 
You can tell it your website, at least. I guess the timezone format would be e.g. -5:00 for me.
@UserBlanko There probably are. :-) But this is the best way.
 
I am hoping after exams, then I would try "programming"
now my teacher is out to kill me with his paper hahaha~
 
@RebolBot
parse "[Rebol] and [Red] are the [Topic]" [
    some [
        thru "["
        copy term to "]"
        (print term)
    ]
    to end
]
 
10:07 AM
; Brought to you by: try.rebol.nl
Rebol
Red
Topic
== true
 
@UserBlanko Well, what we do here is different, and if you think this is cool then do look at the download size...
Half a megabyte. No installation dependencies.
 
how is it possible for half megabyte?!
 
@UserBlanko Careful control of dependencies, and basically not budging from the "old ways".
It really is kind of a "religious" thing with Rebol and Red, that if you have megabytes upon megabytes of code, even if it is open source... how can you know all that code is correct?
So it's important to keep rethinking and rethinking.
The evaluation model is so different from what you know.
 
@HostileFork I am kind of new to programming I don't know what are the "old ways"
 
@RebolBot
code: [print "Hello!"]
if 1 < 2 code
if 3 < 4 code
 
10:14 AM
; Brought to you by: try.rebol.nl
Hello!
Hello!
 
code is a variable?
 
6
Q: 64kB demos, how do they work?

trVoldemortI've seen some programs showing amazing highly detailed 3d scenes with soundtracks, but what shocked me is that they are all smaller than 64kB! How do these programs work?

 
@UserBlanko It's probably timelord technology. I rather wonder how everything else is so big and unnecessarily complex.
 
@RebolBot
stuff: [code: code :code 'code]
foreach elem stuff [
    print ["The type of" mold elem "is" mold type? elem]
]
 
; Brought to you by: try.rebol.nl
The type of code: is set-word!
The type of code is word!
The type of :code is get-word!
The type of code is word!
 
10:17 AM
:code is get word like of like C#?
wait let me re-phrase
:code is something like getter and setter in c#?
 
@UserBlanko C# is not "homoiconic" so I imagine not. It's merely a symbol. The code in Rebol itself is a data structure. You have seen I can make a list of elements that looks like data perhaps code: ["Hello" print] and it's up to me if I want to treat that as data or as code. If I DO it, then it becomes code. Until then I can work with it, reverse it, walk over it...
The property exists in Lisp also: en.wikipedia.org/wiki/Homoiconicity
The default evaluator in DO has a way of processing these elements. But if you do not ever DO them but just look at them, you can write your own "evaluator" to treat them differently.
It's a toolkit for making your own languages, without having to do all the boring work of matching up parentheses or brackets or strings. You have something that is kind of like XML (but better) that happens to be able to nicely dress up as an "ordinary" looking programming language.
 
@HostileFork there are so many things I don't know, is it like your blog of what you said? kind of like the number 2 but if I want to use it as a variable I could use $2?
 
@RebolBot
$2.00 + $0.50
 
; Brought to you by: try.rebol.nl
== $2.50
 
@UserBlanko In Rebol, $ is taken for currency
In computing and electronic systems, binary-coded decimal (BCD) is a class of binary encodings of decimal numbers where each decimal digit is represented by a fixed number of bits, usually four or eight, although other sizes (such as six bits) have been used historically. Special bit patterns are sometimes used for a sign or for other indications (e.g., error or overflow). In byte-oriented systems (i.e. most modern computers), the term uncompressed BCD usually implies a full byte for each digit (often including a sign), whereas packed BCD typically encodes two decimal digits within a single byte...
It's important that currency be based on BCD
 
10:23 AM
I am confused, is there a place I could learn the basic?
 
@UserBlanko Here (this chat room) is a good place. Reading the rebol tag on SO can be interesting and you can see what interests you. But you might read Why Rebol, Red, and the Parse dialect are Cool to start.
@UserBlanko Old but good on philosophy: Is Rebol Actually a Revolution?. Dated and due for an update but perhaps interesting in concept still: Major Quirks of the Rebol Language. Cool because it shows my clay art if nothing else: The Flexible Series as a Core Concept of Rebol
 
@HostileFork hahaha hold on, you are going too fast, I have to study for tests first then I be back on Wednesday to find you is that cool? :)
 
@UserBlanko We're here to discuss, teach, plan, Rebol stuff. So always a welcome topic here, with me or anyone else.
 
oh correct me if I am wrong Rebol is a language right?
okay thanks @HostileFork i have to start studying already
 
Yes, although it has an oddity that it is also sort of a data format. You might say Rebol has an aspect in which it is like XML.
But for the sake of conversation, yes. It's a language. :-)
 
11:14 AM
@iArnold So who is iRonald? :-)
You on a typo binge, or have you found a fan?
 
11:46 AM
Fixing a Red bug and tweeting at 30000 fts over north Russia...finally feeling like it's 21th century! #onboardwifi #airfrance
First Red commit from Space ;) https://github.com/red/red/commit/0260a6cecf04f304ae69e72961dce42a3b293aae
0
A: String searching in Rebol or Red

draegtunNo surprises that HostileFork answer covers everything beautifully! +1 Just wanted to add an alternative solution to point 1 that i use regularly: >> attempt [index? find STR "z"] == 18 >> attempt [index? find STR "n"] == none Online documentation for Rebol 2 attempt & Rebol 3 attempt

 
12:19 PM
@WiseGenius what about @@ as literal UNSET! and ## as literal NONE! ?
 
@HostileFork I was thinking that too. I just wasn't sure how often unset! is used?
How does this one work?
“any-word-or-string@{...} (construction syntax for words, strings)”
 
@WiseGenius In source, pretty much absolutely never.
>> x: #[unset!]
 
; Brought to you by: try.rebol.nl
; rebol.com/r3/docs/errors/script-need-value.html
    *** ERROR
** Script error: x: needs a value
** Where:
** Near: try load/all join %/users/try-REBOL/data/ system/script/args...
 
They're hard to assign to things. :-/
So for the heck of it, I'm running this by Douglas Crockford and seeing if he chooses to say anything about it.
Can't hurt to ask...
 
12:42 PM
@RebolBot This is an exciting time to be alive!
 
@WiseGenius What do you mean?
 
I mean that many cool proposals seem to be coming together nicely.
 
Well, mail sent. And now time for me to sleep some.
I do think that the caret escaping was a bit of a watershed, and the rest of this sort of involves just practically starting from what we know about the needs of JSON-like clients
 
@HostileFork Mind forwarding me a copy?
 
If I could say there's one big "Hmm" remaining, it's whether or not to as a whole think it important that brackets and parentheses allow crunching up against other things on their outside.
@WiseGenius I may no longer have your address, I kind of delete as much as I can. Send me an email and I will forward it to that address.
 
12:59 PM
@HostileFork I used to always put a space between the 2 blocks for either. Then I discovered I didn't have to. Needing no space on the insides of the brackets seemed obvious to me, though.
But then you would have to ask what does [...][...] mean? And I suspect forgetting such a space would be pretty common.
 
Well the thing is kind of like what @earl likes to point out, is that the best proposals are the ones where you can break them down so that they don't necessarily all depend on each other. What's nice about this is that it doesn't force any of that to change. And with ## as none we don't even technically have to change the string behavior either, because ##{...} can load as ## {...} and be fine
 
@HostileFork Yes.
 
It's best to see everything as separate as it can be, but I think the union of the caret escaping and this new literals syntax are two things that need to go together to get the proper Ren
Anyway, TTYL. Keep thinkin'...
 
1:18 PM
@HostileFork Goodnight.
 
2:09 PM
@WiseGenius I will summarize Douglas Crockford's first response (which I found a bit flippant but asked him for a less flippant answer) to be summarizable as: "There's not enough value in the weird string constant form {...} to take it for strings, so take it for your object literal form, instead of doing something wacky like @(...)"
 
@HostileFork Haha!
Actually, that's what I imagined he'd be thinking, which isn't surprizing, really.
 
My rough response being that object literal forms are not the norm in Rebol, because imperative composition is more flexible. Flat unabstractable literal objects that you can't COMPOSE is Rebol's exceptional case.
 
2:31 PM
@RebolBot
x: make map! [foo: true]
type? x/foo
 
; Brought to you by: try.rebol.nl
== word!
 
@RebolBot
x: make object! [foo: true]
type? x/foo
 
; Brought to you by: try.rebol.nl
== logic!
 
@RebolBot
x: #[object! [a: true]]
type? x/a
 
; Brought to you by: try.rebol.nl
== logic!
 
2:36 PM
>> mold/all context [a: true]
 
; Brought to you by: try.rebol.nl
== "#[object! [^/    a: #[true]^/]]"
 
>> mold/all context [a: none]
 
; Brought to you by: try.rebol.nl
== "#[object! [^/    a: #[none]^/]]"
 
@RebolBot
x: #[object! [a: b]]
type? x/a
 
; Brought to you by: try.rebol.nl
== word!
 
2:40 PM
@RebolBot
x: #[object! [a: none]]
type? x/a
 
; Brought to you by: try.rebol.nl
== none!
 
Seems there's indeed a partial eval hack for object literals in place. Oh my, the times ...
 
2:53 PM
@HostileFork Not to agree with him, but just speaking of {...}, if it were a different language with similar syntax, I'd rather be using “...” for string delimiters.
The font changed it. That was meant to be “...”.
I personally believe that Rebol is too far influenced by the QWERTY keyboard layout (eg. [...] because no shift needed on QWERTY). I believe a language shouldn't change to fit a keyboard layout, but that the keyboard layout should change to fit the language (and that QWERTY should change anyway as it's best for no language).
But I wouldn't propose anything based on that belief because I don't think it would be in line with what Rebol is.
 
3:21 PM
https://github.com/red/red/pull/1048
GitHub
Red Pull Req—DOCS: fix example of using a nested exception.
qtxie
1425115185
 
 
4 hours later…
7:38 PM
One that is still hopeful that @name notation will come to pass, but then I don't see a conflict as yet with some of the propositions. This notation is fairly well spread and there'd be value in being able to express it: [@RebolBot 28-Feb-2015/14:36:23-5:00 "That's very interesting."]
I'm not against ## for literal NONE! though the repeat character looks a little ugly, perhaps it could be varied: none = #! true = #> false = #< (I'm not entirely serious, but...)
@earl Yikes.
 
7:58 PM
Kicking Topaz around again out of JS curiosity, added an EVALUATE function that will evaluate Javascript statements. While just a wrapper for eval() and spartan in it's return value, it does make Topaz a little less lonely in the browser.
 
 
1 hour later…
9:12 PM
@HostileFork My thanks to everyone, esp Fork, for help and guidance. Will do my best to be helpful in turn once I get past the training wheel stage.
 
 
2 hours later…
11:18 PM
@WiseGenius You and McCarthy both. He lost, and then, finally, gave up. So, good luck!
@HostileFork I know this is totally not helping, sorry!
>> [[[[ [[[]]] [[[]]] ]]]]
 
; Brought to you by: try.rebol.nl
== [[[[[[[]]] [[[]]]]]]]
 
I like my way better ...
Please, I know, it is a corner case, I beg your forgiveness.
 
11:41 PM
And I should say I think Carl even thought about this, it cries out for newlines in blocks.
>> load {[[[[^/[[[]]][[[]]]]]]]}
 
; Brought to you by: try.rebol.nl
== [[[[
                [[[]]] [[[]]]
            ]]]]
 
Well, that's looks a little stupider than I thought. But the idea is clear, I hope :)
 

« first day (1581 days earlier)      last day (2199 days later) »