>> files: [%app.red %backup.txt %r1.r %r2.r %r3.r] == [%app.red %backup.txt %r1.r %r2.r %r3.r] >> list-of-rules:  ==  >> foreach f files [if equal? suffix? f ".r" [append list-of-rules f]] == [%r1.r %r2.r %r3.r]
I know how to use it inside red parse, but have not ideas how work with it in classic red. Something like?
l: foreach f files [if equal? suffix? f ".r" [collect keep f]]
And it's seems that keep can't use outside red parse:
>> ? keep No matching values were found in the global context.
keepso they align with standard Red functions, but they may behave differently. It may seem strange at first, but it becomes natural before too long for most people.
parse. But we wouldn't be as effective without it, and our code would be more complicated.
asset. The military's meaning of
assetwould be different than the financial analyst's meaning of
do/nextand check the mode again (switch if needed)
exitthat sets the position and breaks out of parse, then after a break (in do-mode again), continue from that position
+is an operator, but at some point it may change into a value or a function and you need to be up to date with this change. The only way to be up to date is to evaluate ;)
Well, I do not have enough knowledge to understand the pre lexer and after lexer and macros level but the do/next and switching to parse is at my reach.
pre-lexer is just a big string,
system/lexer/pre-load thing abuses that
after lexing it's a block of Red values, there goes preprocessor and expands macros
do on the result
Also, seeking docs and examples on pre lexer, could you point me to something?
search wiki for pre-load, there must be something