<andrewrk>
if they don't make them publicly available without registering, I'll just upload them to youtube
<andrewrk>
I didn't sign any nonexclusivity contract
<fengb>
Oh 2 talks the same event? Yowch
<fengb>
Are they still live?
<andrewrk>
no, pre recorded. both done
foobles has joined #zig
<foobles>
how do you make a request for review on github? maybe because I am not part of the "zig team" or something, but there is nobody listed under the "reviewers" tab
kevsmith has quit [Remote host closed the connection]
kevsmith has joined #zig
<andrewrk>
foobles, I think the problem here is not lack of process but lack of contributor time (including mine) and adding process doesn't necessarily save time, and in fact can actually remove time, making the problem worse
<andrewrk>
you joined at a particularly difficult time when pull requests are piling up a lot, but I promise you I'm working on getting more funding and qualified people to merge PRs. it'll take a while though
nephele_ has joined #zig
<andrewrk>
in the meantime there's just going to be a high latency for some PRs, and that's the unfortunate way it goes
nephele has quit [Ping timeout: 246 seconds]
nephele_ is now known as nephele
marijnfs_ has joined #zig
<fengb>
Oh boy, sounds like a major announcement soon
marijnfs has quit [Ping timeout: 265 seconds]
ur5us has quit [Ping timeout: 260 seconds]
<foobles>
oh alright, thanks andrewrk
<foobles>
understood :]
ur5us has joined #zig
dddddd_ has quit [Ping timeout: 260 seconds]
ur5us has quit [Ping timeout: 244 seconds]
ur5us has joined #zig
<foobles>
I know you can say `error.foo` to create a new error value
<foobles>
of an anonymous error type
<foobles>
because it expands to `error { foo }.foo`
<foobles>
but then how does just saying `anyerror.foo` work (assuming no other error set defines foo)?
benjif has quit [Ping timeout: 272 seconds]
<foobles>
because it seems to behave identically to just `error.foo`
<foobles>
andrewrk but are you able to just invent new error values out of nothing with `anyerror`?
<foobles>
like is that intended behavior?
<foobles>
or does it mean global as in "it contains any possible error at all"
<foobles>
and if so, doesn't the fact that `error.foo` and `anyerror.foo` both do the same thing go against the "one obvious way to do things" principle?
<andrewrk>
foobles, yes, `anyerror` is the global error set, including all errors
aerona has quit [Remote host closed the connection]
<foobles>
ahh, i thought it was just "all errors of error sets in scope"
<andrewrk>
they don't do exactly the same thing
aerona has joined #zig
<andrewrk>
`@typeOf(error.Foo)` is an anonymous error set with only 1 error in it
<andrewrk>
`@typeOf(Foo.Name)` is Foo
<andrewrk>
so if you do anyerror.Name then you have the global error set, which will not coerce to a smaller one
<andrewrk>
you almost never want that
<foobles>
Oh i see
<foobles>
but if you have `const Foo = error { foo, bar }`, `error.foo` can coerce to that
<foobles>
interesting
<andrewrk>
exactly
<foobles>
its seems a bit unclear though, an kinda non-obvious. why does `anyerror` support any possible error, and not just the names of already defined error values?
<andrewrk>
that's what it is, any defined error values, global to the entire application
<andrewrk>
you can still get a safety panic from @intToError(anyerror, x)
<andrewrk>
if your argument is that `anyerror.Foo` should not cause a particular error name to come into existence, then I think you may be on to something
<foobles>
yeah, that's what im talking about more
<foobles>
like it makes sense to be able to do `anyerror.AnythingDefinedInTheProgram`
<foobles>
but for it to make new values seems weird
retrhelo has joined #zig
<retrhelo>
leave
retrhelo has left #zig [#zig]
retrhelo has joined #zig
aerona has quit [Quit: Leaving]
<fengb>
anyerror encompasses itself too. You changed the global set by querying it!
<foobles>
right!
<foobles>
but thats super weird!
<foobles>
and probably not very useful
foobles has quit [Ping timeout: 245 seconds]
xackus_ has joined #zig
retrhelo has quit [Ping timeout: 272 seconds]
cole-h has quit [Quit: Goodbye]
ur5us has quit [Ping timeout: 260 seconds]
metaleap has joined #zig
waleee-cl has quit [Quit: Connection closed for inactivity]
factormystic has quit [Read error: Connection reset by peer]
nycex has quit [Remote host closed the connection]
chapl has quit [Remote host closed the connection]
chapl has joined #zig
<oats>
it always felt kinda weirdly bolted on in lua
chapl has quit [Remote host closed the connection]
chapl has joined #zig
nycex has joined #zig
waleee-cl has joined #zig
<chapl>
Hey! Somebody mind elaborating on what the difference between InStream#read() and InStream#readAll() is?
<alexnask>
read may read less bytes than the buffer length
<alexnask>
readAll reads until the buffer is full or read() returns 0 bytes read
<andrewrk>
operating systems have the concept of "short reads" which unfortunately is sometimes semantically meaningful
<andrewrk>
but almost always you want readAll
<chapl>
Alright. If I have a buffer with 512 cap, and readAll says aight look, read 234 bytes... are the remaining 278 bytes in the buffer still undefined? I'd assume yes
gazler has quit [Quit: Leaving]
<andrewrk>
yes
<chapl>
Ok cool. I have never done manual memory management in detail so one more question: People already explained to me that the number how many bytes were read is useful for trimming the buffer down to the amt of bytes read. How'd I do that?
wootehfoot has quit [Read error: Connection reset by peer]
<gpanders>
chapl: Allocator.shrink or Allocator.realloc
dimenus has quit [Quit: WeeChat 2.8]
metaleap has joined #zig
dimenus has joined #zig
ifreund has quit [Ping timeout: 246 seconds]
ifreund has joined #zig
dimenus has quit [Quit: WeeChat 2.8]
dimenus has joined #zig
plumm has joined #zig
<plumm>
andrewrk: for out streams, is there any way to have a non async write function?
<andrewrk>
plumm, the async-ness of the write function depends entirely on the underlying write function of the stream
dimenus has quit [Client Quit]
dimenus has joined #zig
<plumm>
damn, so theres no way to write to a socket from a different thread?
ifreund has quit [Ping timeout: 264 seconds]
<andrewrk>
you also have the option to use a nosuspend block to assert at runtime that async functions will not suspend
<plumm>
I don't quite fully understand async yet, was waiting for the talk for that
<plumm>
I only opted to use evented io because thats required for the tcp connection
<andrewrk>
if you're using the std lib event loop, I don't see why you would want to write to a socket from a different thread
<andrewrk>
it's not required
<andrewrk>
you can use blocking I/O with networking just fine
<oats>
hmm, I was really hoping `&.{ foo, bar }` would work as short syntax for a slice literal :<
pystub has joined #zig
<andrewrk>
I think that is likely to be improved to work as
<andrewrk>
s/ as//
<andrewrk>
I can't think of any reason to not make that work
<plumm>
do you have any idea why accessing an outStream() from another thread would cause EXC_BAD_ACCESS?
<tdeo>
do you get a backtrace?
<plumm>
no :(
<plumm>
I only found this out using lldb
<tdeo>
`bt` for a backtrace in lldb
<plumm>
well yeah there is one but its just startFn -> posixThreadMain -> libsystem_pthread ...
<tdeo>
what function does it happen in?
zfoo has quit [Remote host closed the connection]
metaleap has joined #zig
<plumm>
i have a function that opens a socket to an address using tcpConnectToAddress, i spawn a thread that has the write outStream and thats where it begins
Hesaam has joined #zig
Hesaam has quit [Ping timeout: 258 seconds]
Chris660 has joined #zig
wootehfoot has joined #zig
mcf has quit [Excess Flood]
mforney has joined #zig
alexnask_ has joined #zig
alexnask has quit [Ping timeout: 272 seconds]
mforney is now known as mcf
alexnask_ is now known as alexnask
chapl has quit [Quit: Leaving]
benjif has joined #zig
gpanders has quit [Ping timeout: 264 seconds]
gpanders has joined #zig
chapl has joined #zig
<chapl>
andrewrk: Mind starting a livestream? Would like to see more No-LLVM work :P
<plumm>
^
constptr has quit [Quit: Connection closed for inactivity]
<layneson>
^^
layneson has quit [Quit: WeeChat 2.8]
<chapl>
if he'd just respond.. :'D
ifreund has quit [Ping timeout: 256 seconds]
ifreund has joined #zig
dimenus|home has joined #zig
dimenus has quit [Killed (orwell.freenode.net (Nickname regained by services))]
dimenus|home is now known as dimenus
Guest70237 has joined #zig
dimenus has quit [Quit: WeeChat 2.8]
Guest70237 is now known as dimenus
kristoff_it has joined #zig
ifreund has quit [Ping timeout: 246 seconds]
slowtyper has quit [Ping timeout: 246 seconds]
ifreund has joined #zig
Akuli has quit [Quit: Leaving]
slowtyper has joined #zig
ur5us has joined #zig
Chris660 has quit [Ping timeout: 256 seconds]
Kingsquee has joined #zig
metaleap has quit [Quit: Leaving]
wootehfoot has quit [Read error: Connection reset by peer]
ifreund has quit [Ping timeout: 272 seconds]
ifreund has joined #zig
slowtyper has quit [Ping timeout: 260 seconds]
<plumm>
hes heads down in work, we must'nt disturb
FireFox317 has joined #zig
<plumm>
:^) hi firefox
<waleee-cl>
FireFox317 got an upgrade today
<FireFox317>
Hey :D
<waleee-cl>
(firefox that is)
<FireFox317>
andrewrk, quick question, we are debugging some networking code on kristoff_it stream. Do you have time to join? We are not exactly sure what the issue is
<FireFox317>
it comes down to the connect function in os.zig, should it be waiting on writable or readable or only on writable?
<oats>
is "error" a reserved keyword?
<shakesoda>
yes
<tdeo>
yes
nycex has quit [Ping timeout: 240 seconds]
nycex has joined #zig
st4ll1 has quit [Ping timeout: 260 seconds]
st4ll1 has joined #zig
<kristoff_it>
Hello, during my stream today I discussed with a few people from the Zig community about the idea of doing some kind of Zig virtual meetup in the near future. If you're interested I wrote a (extremely rough) first idea of how it should look like. If you have any comment please feel free to let me know and/or open an issue there: https://github.com/kristoff-it/zig-meetup
FireFox317 has quit [Ping timeout: 264 seconds]
kristoff_it has quit [Ping timeout: 272 seconds]
ifreund has quit [Ping timeout: 246 seconds]
factormystic has quit [Read error: Connection reset by peer]