<Alhamdulillah[m]>
<ox1eef_> "Alhamdulillah: i like your irc..." <- idkwtf: uh really ? You know the meaning right ? Btw I'm not sure how it looks for you, is it Alhamdulillah or something else, because I'm using matrix bridge to this irc
<Alhamdulillah[m]>
* uh really ? You know the meaning right ? Btw I'm not sure how it looks for you, is it Alhamdulillah or something else, because I'm using matrix bridge to this irc
<havenwood>
Updated to show a pattern matching version, for fun.
<FullMetalStacker>
Why does my block modify both n3 and new??
<leah2>
because it contains the same array
idkwtf has joined #ruby
<leah2>
also dont paste long outputs here
hightower2 has joined #ruby
<FullMetalStacker>
leah2 so the array is not copied but just linked while the integer in the first example was copied?
hightower2 has quit [Remote host closed the connection]
hightower2 has joined #ruby
hightower2 has quit [Read error: Connection reset by peer]
<leah2>
yes
<leah2>
use new = n3.dup if you wanna do that
<leah2>
integers are immutable and passed by value
hightower2 has joined #ruby
<leah2>
most objects are references tho
<FullMetalStacker>
great, thank you very much!
hightower2 has quit [Read error: Connection reset by peer]
<FullMetalStacker>
learned again something very valuable today, thank you, leah2!
hightower2 has joined #ruby
hightower2 has quit [Ping timeout: 268 seconds]
<leah2>
yw :)
alexherbo2 has joined #ruby
Laplace has quit [Quit: Connection closed for inactivity]
<isene>
ox1eef_: Thanks a plenty for your help, I simply boiled it all down to a simple flushing mechanism for STDIN to remove remaining garbage from control chars:
<isene>
while IO.select([STDIN], [], [], 0) != nil
<isene>
STDIN.getch
<isene>
end
<leah2>
oO
<leah2>
ah with timeout 0. require 'io/console'; true while STDIN.getch(timeout: 0)
<leah2>
easier maybe
<leah2>
or STDIN.read_partial
reset has quit [Quit: reset]
Linux_Kerio has joined #ruby
___nick___ has joined #ruby
alexherbo2 has quit [Remote host closed the connection]
<idkwtf>
Having said that, it's time to check out which clubs are open :D
<idkwtf>
Bye y'all
idkwtf has quit [Quit: Lost terminal]
erblack90 has joined #ruby
erblack90 is now known as erblack
erblack is now known as erb
erb has quit [Client Quit]
erb has joined #ruby
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
D_A_N_ has joined #ruby
jhass has quit [Quit: Bye]
tirnanog has joined #ruby
jhass has joined #ruby
<_73>
With Parslet, can I create a rule that matches text that another rule *cannot* match? For example I have a grammar where a "section" is a "section_tag" followed by a "section_body". A section_tag is an alphabetic sequence surrounded by square brackets. A section_body is any text that cannot be matched as a section_tag. Here is the code I have: http://dpaste.com/BHT6R9VQG
Aminda has quit [Read error: Connection reset by peer]
Aminda has joined #ruby
gordea has joined #ruby
gordea has quit [Client Quit]
reset has joined #ruby
aeris has quit [Remote host closed the connection]
aeris has joined #ruby
aeris has quit [Ping timeout: 255 seconds]
aeris has joined #ruby
gordea has joined #ruby
erb has quit [Quit: ERC 5.4 (IRC client for GNU Emacs 28.1)]
kotrcka has quit [Remote host closed the connection]
grokify has joined #ruby
grokify has quit [Remote host closed the connection]
<jiggawatt>
bye idkwtf
ur5us has joined #ruby
<Alhamdulillah[m]>
Where r u from?
Sheilong has joined #ruby
grokify has joined #ruby
dionysus69 has joined #ruby
grokify has quit [Ping timeout: 265 seconds]
coderpath has joined #ruby
Linux_Kerio has quit [Ping timeout: 264 seconds]
ur5us has quit [Quit: Leaving]
<_73>
Hey, I figured it out. "absent?" is a predicate and doesn't actually parse anything, it just looks ahead. The trick is to say "(section_tag.absent? >> any).repeat.as(:body)"
phenom has quit [Ping timeout: 256 seconds]
phenom has joined #ruby
swaggboi has joined #ruby
___nick___ has quit [Ping timeout: 260 seconds]
otisolsen70 has quit [Quit: Leaving]
_ht has quit [Quit: _ht]
ox1eef_ has quit [Quit: WeeChat 3.7]
ox1eef_ has joined #ruby
dionysus69 has quit [Ping timeout: 268 seconds]
supay has joined #ruby
FetidToot has quit [Ping timeout: 248 seconds]
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
some14u has joined #ruby
some14u has quit [Client Quit]
some14u has joined #ruby
cartdrige has joined #ruby
Sheilong has quit [Quit: Connection closed for inactivity]
crax23 has joined #ruby
cartdrige has quit [Ping timeout: 265 seconds]
FetidToot has joined #ruby
FetidToot has quit [Quit: Ping timeout (120 seconds)]