code logs -> 2017 -> Thu, 30 Mar 2017< code.20170329.log - code.20170331.log >
--- Log opened Thu Mar 30 00:00:14 2017
00:11 Jessikat [Jessica@Nightstar-bt5k4h.81.in-addr.arpa] has quit [[NS] Quit: Leaving]
00:24 Jessikat [Jessikat@Nightstar-klb0kn.dab.02.net] has joined #code
00:46 Jessikat` [Jessikat@Nightstar-5do2sp.dab.02.net] has joined #code
00:48 * celticminstrel wonders if Boost is the best choice for coroutines...
00:48 Jessikat [Jessikat@Nightstar-klb0kn.dab.02.net] has quit [Ping timeout: 121 seconds]
00:51 Alek [Alek@Nightstar-7or629.il.comcast.net] has quit [Ping timeout: 121 seconds]
00:53 Alek [Alek@Nightstar-7or629.il.comcast.net] has joined #code
00:53 mode/#code [+o Alek] by ChanServ
00:57 Alek [Alek@Nightstar-7or629.il.comcast.net] has quit [Ping timeout: 121 seconds]
00:57
<&McMartin>
It's not ideal but you're hard-pressed to find a better one for C++
00:58
<&McMartin>
Otherwise your best option is to use a language with built-in support for them or something that looks like them
01:01 Alek [Alek@Nightstar-7or629.il.comcast.net] has joined #code
01:01 mode/#code [+o Alek] by ChanServ
01:31 Turaiel[Offline] is now known as Turaiel
02:07
<&Derakon>
Mental note: when writing interactive commandline programs, there is an important difference between sys.stdin.read() and sys.stdin.readline().
02:09
<&McMartin>
... yes
02:11 ion [Owner@Nightstar-gmbj85.vs.shawcable.net] has quit [Ping timeout: 121 seconds]
02:14 Alek [Alek@Nightstar-7or629.il.comcast.net] has quit [Ping timeout: 121 seconds]
02:15 ion [Owner@Nightstar-gmbj85.vs.shawcable.net] has joined #code
02:18 Alek [Alek@Nightstar-7or629.il.comcast.net] has joined #code
02:18 mode/#code [+o Alek] by ChanServ
02:31
<&Derakon>
Ahh, regexes.
02:31
<&Derakon>
((?:\d*?)):?((?:\d*?)):?(\d+),?(\d*)
02:31
<&Derakon>
Sure, that makes sense.
02:35 RchrdB [RchrdB@Nightstar-qe9.aug.187.81.IP] has quit [Ping timeout: 121 seconds]
03:02
<&Derakon>
First draft of subtitle-writing script works...until my timestamp calculation logic hits the first minute. Whoops.
03:02
<&Derakon>
Guess I get to write the subtitle-amending-and-appending logic earlier than expected.
03:08 * Vornicus can understand that.
03:26
<&Derakon>
Okay, I've been working on this for an hour and a half, and I have one minute of subtitles!
03:26
<&Derakon>
The curse of the programmer.
03:57 Turaiel is now known as Turaiel[Offline]
04:24
< Azash>
((?:\d*?)) < What does the second question mark do?
04:27
<~Vornicus>
Minimizes match length
04:27
< Azash>
Oh, huh
04:28
< Azash>
Thank you, I didn't know about that
04:28
< Azash>
Is there a functional difference between ((?:\d*?)) and (\d*?) ?
04:28
<~Vornicus>
I don't understand why der did that, that's for sure
04:29 * Azash suspects there was more in the outer parentheses originally and it was left as-is when culled
04:32
< Azash>
Also question about that original regexp, if you had, say, 00:01:51,123, wouldn't it match (,,00,) rather than (00,01,51,123)?
04:42
<~Vornicus>
no, because it's still not allowed to *skip* things
04:54 Netsplit Kakrafoon.Nightstar.Net <-> Krikkit.Nightstar.Net quits: @JustBob, @gnolam, @celticminstrel, @Pi, sshine, @[R], @Syloq, @jeroud, @ToxicFrog, @PinkFreud
05:03 VirusJTG [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has quit [Connection closed]
05:03 VirusJTG [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has joined #code
05:08 Derakon is now known as Derakon[AFK]
05:09
< Azash>
Vornicus: So \d*? is at least one token long? Or?
05:09
< Azash>
I mean yes it would be different if it was anchored to something like ^regex foo$ or whatever, but
05:10
<~Vornicus>
At least zero tokens long, but: regex always always matches the *earliest thing it can*
05:11
<~Vornicus>
And it never skips characters except for the lead
05:12
<~Vornicus>
so ((?:\d*?)):?((?:\d*?)):?(\d+),?(\d*) will match to (00, 01, 51, 123) for your sample, because that's the earliest matching thing.
05:12
<~Vornicus>
On the other hand, it will match 01:51,123 to (,01,51,123)
05:18
<~Vornicus>
THis is because the first capture doesn't consume anything, because it doesn't have to to proceed.
05:29
< Azash>
Vornicus: Right but I meant that if you aren't actually binding the end of the regex to the end of the string somehow
05:30
< Azash>
Since both the colons are optional and the only capture that must be at least 1 token is the third one and that's the first greedy one
05:30
<~Vornicus>
That one must start way later
05:30
<~Vornicus>
Because of that, it's not the one that gets found
05:30
<~Vornicus>
regex always always matches the earliest thign it can.
05:32
<~Vornicus>
the match that collects all four pieces starts at position 0; the one you suggest starts at position 6.
05:32
< Azash>
06:32 < Azash> Also question about that original regexp, if you had, say, 00:01:51,123, wouldn't it match (,,00,) rather than (00,01,51,123)?
05:33
< Azash>
The (a,b,c,d) refers to the captures
05:33
< Azash>
I'm asking if the third capture would match the starting 00 and the rest be empty
05:33
<~Vornicus>
Can't.
05:34 * Vornicus eyes
05:36
<~Vornicus>
wait, I guess it cn, how is it doing that
05:37
< Azash>
Vornicus: Because ((?:\d*?)):?((?:\d*?)):?(\d+),?(\d*) is, broken down
05:38
<~Vornicus>
yeah, okay, it is. how the heck do you prevent it
05:38
< Azash>
Anchor it
05:38
< Azash>
I presume that for example this is meant to continue with text
05:38
<~Vornicus>
so you'd probably glom a space on there and then it'd work
05:38
< Azash>
^((?:\d*?)):?((?:\d*?)):?(\d+),?(\d*) +(.+)$
06:19 Syloq [Syloq@NetworkAdministrator.Nightstar.Net] has joined #code
06:28 Jessikat` is now known as Jessikat
07:15 Jessikat` [Jessikat@Nightstar-lg2.jtr.132.82.IP] has joined #code
07:19 Jessikat [Jessikat@Nightstar-5do2sp.dab.02.net] has quit [Ping timeout: 121 seconds]
09:30 Jessikat` [Jessikat@Nightstar-lg2.jtr.132.82.IP] has quit [[NS] Quit: Bye]
09:51 JBeshir [namegduf@Nightstar-lcgn9d.beshir.org] has quit [Ping timeout: 121 seconds]
10:45 Alek [Alek@Nightstar-7or629.il.comcast.net] has quit [Ping timeout: 121 seconds]
10:48 Alek [Alek@Nightstar-7or629.il.comcast.net] has joined #code
11:44 Jessikat [Jessikat@Nightstar-lg2.jtr.132.82.IP] has joined #code
11:45 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has quit [Operation timed out]
11:49 RchrdB [RchrdB@Nightstar-qe9.aug.187.81.IP] has joined #code
13:03 RchrdB [RchrdB@Nightstar-qe9.aug.187.81.IP] has quit [Operation timed out]
13:46 Jessikat` [Jessikat@Nightstar-j1c0nd.dab.02.net] has joined #code
13:48 Jessikat [Jessikat@Nightstar-lg2.jtr.132.82.IP] has quit [Ping timeout: 121 seconds]
15:32 RchrdB [RchrdB@Nightstar-qe9.aug.187.81.IP] has joined #code
15:32 gnolam [lenin@Nightstar-09nsce.cust.bahnhof.se] has joined #code
15:32 PinkFreud [WhyNot@Pinkfreud.is.really.fuckin.lame.nightstar.net] has joined #code
15:32 JustBob [justbob@Nightstar.Customer.Dissatisfaction.Administrator] has joined #code
15:32 [R] [rstamer@genoce.org] has joined #code
15:32 ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has joined #code
15:32 sshine [simon@Nightstar-c7dik3.monoid.co] has joined #code
15:32 jeroud [sid10043@Nightstar-kt1.9ff.184.192.IP] has joined #code
15:32 Pi [sid25146@Nightstar-a0t.9ff.184.192.IP] has joined #code
15:32 celmin|sleep [celticminst@Nightstar-a7q7jt.dsl.bell.ca] has joined #code
15:32 ServerMode/#code [+oooaoaoaooo gnolam PinkFreud JustBob [R] [R] ToxicFrog ToxicFrog jeroud jeroud Pi celmin|sleep] by *.Nightstar.Net
15:32 mode/#code [+o Syloq] by ChanServ
15:32 mode/#code [+o Alek] by ChanServ
16:53 Alek [Alek@Nightstar-7or629.il.comcast.net] has quit [Ping timeout: 121 seconds]
16:56 Alek [Alek@Nightstar-7or629.il.comcast.net] has joined #code
16:56 mode/#code [+o Alek] by ChanServ
17:42 Jessikat` [Jessikat@Nightstar-j1c0nd.dab.02.net] has quit [[NS] Quit: Bye]
18:04 ion [Owner@Nightstar-gmbj85.vs.shawcable.net] has quit [[NS] Quit: Whoops, it broke!]
20:01 Vornicus [Vorn@ServerAdministrator.Nightstar.Net] has joined #code
20:01 mode/#code [+qo Vornicus Vornicus] by ChanServ
20:04 Jessikat [Jessica@Nightstar-bt5k4h.81.in-addr.arpa] has joined #code
20:12 Kizor [moryok@Nightstar-e0a4sm.utu.fi] has joined #code
20:40 celmin|sleep is now known as celticminstrel
20:59 IRCFrEAK [gk.1wm.su@Nightstar-nq3.v95.144.198.IP] has joined #code
21:00 IRCFrEAK [gk.1wm.su@Nightstar-nq3.v95.144.198.IP] has quit [RecvQ exceeded]
21:05 IRCFrEAK [gk.1wm.su@Nightstar-nq3.v95.144.198.IP] has joined #code
21:06 IRCFrEAK [gk.1wm.su@Nightstar-nq3.v95.144.198.IP] has quit [RecvQ exceeded]
21:31 Jessikat [Jessica@Nightstar-bt5k4h.81.in-addr.arpa] has quit [[NS] Quit: Leaving]
22:08
< Kizor>
Hello, #code.
22:09
< Kizor>
I need your help, and I'm going to ask for it in the form of an imgur album.
22:09
< Kizor>
http://imgur.com/a/AJjCQ
22:15
< Kizor>
(Or should I cut out the visual aids and move to pastebin?)
22:16
<~Vornicus>
hooray for visual aids
22:20
< Kizor>
These are more like visual harms
22:43 Jessikat [Jessica@Nightstar-bt5k4h.81.in-addr.arpa] has joined #code
23:46 * Jessikat has apparently discovered a case in C++ where she has *had* to define hash and equal_to functors inside the class body, otherwise things just don't work
23:50
<&McMartin>
... is that in fact rare?
--- Log closed Fri Mar 31 00:00:15 2017
code logs -> 2017 -> Thu, 30 Mar 2017< code.20170329.log - code.20170331.log >

[ Latest log file ]