ChanServ changed the topic of #zig to: zig programming language | https://ziglang.org | be excellent to each other | channel logs: https://irclog.whitequark.org/zig/
bjorob has quit [Ping timeout: 260 seconds]
_Vi has quit [Ping timeout: 260 seconds]
dimenus has joined #zig
aerona has joined #zig
hamoko[m] has quit [Ping timeout: 246 seconds]
metheflea has quit [Ping timeout: 246 seconds]
metheflea has joined #zig
lanodan has quit [Ping timeout: 260 seconds]
hamoko[m] has joined #zig
lanodan has joined #zig
belgin has joined #zig
stripedpajamas has quit [Quit: sleeping...]
satchmo has quit [Ping timeout: 260 seconds]
nephele_ has joined #zig
nephele has quit [Ping timeout: 256 seconds]
nephele_ is now known as nephele
ifreund has quit [Ping timeout: 240 seconds]
<blueberrypie> looks kinda like a net split
dddddd has quit [Ping timeout: 272 seconds]
<pixelherodev> ?
satchmo has joined #zig
ur5us has quit [Ping timeout: 260 seconds]
ur5us has joined #zig
xackus_ has joined #zig
xackus has quit [Ping timeout: 272 seconds]
stripedpajamas has joined #zig
stripedpajamas has quit [Client Quit]
wozeparrot has quit [Ping timeout: 260 seconds]
stripedpajamas has joined #zig
dimenus has quit [Ping timeout: 260 seconds]
ur5us has quit [Ping timeout: 260 seconds]
waleee-cl has quit [Quit: Connection closed for inactivity]
satchmo has quit [Ping timeout: 272 seconds]
<pixelherodev> andrewrk: what was the command you were using to gather instruction counts?
<pixelherodev> Never mind, `perf stat` works I think
aerona has quit [Quit: Leaving]
slurpie has quit [Ping timeout: 246 seconds]
slurpie has joined #zig
<marler8997> just finished the initial implementation of my small http client, check it out: https://github.com/marler8997/ziget
<daurnimator> marler8997: you should be parsing into a std.http.headers object
<marler8997> yeah
<marler8997> but I didn't need to do it to get it working...so it's put off :)
<marler8997> oh wait, std.http.headers? that's in std lib?
<daurnimator> yes
<marler8997> hmmm, seems unnecessary to create arrays for all the headers
<daurnimator> it's not
<marler8997> I know all the headers I need at compile-time
<daurnimator> header order matters
<marler8997> I don't need to dynamically allocate space for all the known headers
<daurnimator> ?
<marler8997> Each header I need is known at compile-time
<marler8997> I don't need to store a name/value for any header that I don't know how to handle
satchmo has joined #zig
<marler8997> I just saw you said "header order matters"...I didn't know of any headers where order mattered, which ones matter?
satchmo has quit [Ping timeout: 260 seconds]
<marler8997> looks like according to the spec, header order matters if the headers have the same name
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
dermetfan has joined #zig
<daurnimator> yep
<daurnimator> and in other contexts (e.g. request signing) the order of all headers matters
<daurnimator> so reordering is becomes a destructive operations
satchmo has joined #zig
slowtype1 has joined #zig
slowtype1 is now known as slowtyper
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
stripedpajamas has quit [Quit: sleeping...]
tdc has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
haliucinas has quit [Quit: Lost terminal]
haliucinas has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
shakesoda has quit [Quit: Connection closed for inactivity]
satchmo has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
wootehfoot has joined #zig
wootehfoot has quit [Client Quit]
satchmo has quit [Ping timeout: 265 seconds]
satchmo has joined #zig
_Vi has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
FireFox317 has joined #zig
satchmo has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
shakesoda has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
mokafolio has quit [Quit: Bye Bye!]
st4ll1 has joined #zig
wootehfoot has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
_Vi has quit [Ping timeout: 260 seconds]
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
hermier has quit [Ping timeout: 256 seconds]
neceve has joined #zig
alexnask has joined #zig
satchmo has quit [Ping timeout: 265 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
<alexnask> marler8997, Hi, is there any way you can make a separate repo for #5151 while it's under consideration for std? I would like to start writing some extra parts but I dont want to copy paste your whole code into another repo for obvious reasons :P
satchmo has joined #zig
mokafolio has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
slurpie has quit [Ping timeout: 256 seconds]
hermier has joined #zig
satchmo has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
Kingsquee has quit [Quit: Konversation terminated!]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
r4pr0n has joined #zig
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
ifreund has joined #zig
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
st4ll1 has quit [Quit: WeeChat 2.8]
satchmo has quit [Ping timeout: 260 seconds]
APic has left #zig ["*fuup*"]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
_Vi has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
FireFox317 has quit [Remote host closed the connection]
FireFox317 has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
greenfork has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
shakesoda has quit [Quit: Connection closed for inactivity]
satchmo has quit [Ping timeout: 272 seconds]
r4pr0n has quit [Remote host closed the connection]
lanodan has quit [Quit: WeeChat 2.7.1]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
rzezeski has quit [Quit: Connection closed for inactivity]
satchmo has quit [Ping timeout: 246 seconds]
waleee-cl has joined #zig
satchmo has joined #zig
lanodan has joined #zig
satchmo has quit [Ping timeout: 272 seconds]
satchmo has joined #zig
Snetry has quit [Ping timeout: 264 seconds]
Snetry has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
FireFox317 has quit [Remote host closed the connection]
FireFox317 has joined #zig
Snetry has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
FireFox317 has quit [Remote host closed the connection]
FireFox317 has joined #zig
Snetry has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
<marler8997> alexnask: already done over a month ago :) https://github.com/marler8997/zigalloc
jmiven has quit [Quit: reboot]
<alexnask> Huh guess Im blind :)
<marler8997> well no, I didn't mention it in the PR
jmiven has joined #zig
<marler8997> but I knew this would be a bigger project and warranted it's own repo while I work on it and people discuss it
<marler8997> so far not alot of discussion though
<alexnask> Cool, I will experiment with writing some extra parts and using it to build a couple of Allocators
<alexnask> I may even try to plug them into the gotta-go-fast benchmarks and see how they do vs malloc
<marler8997> yeah that would be great
<marler8997> With optimizations, Alloc.c() should be binary identical to calling malloc/free directly
greenfork has quit [Ping timeout: 258 seconds]
satchmo has joined #zig
joepie91 has quit [Quit: killed]
stripedpajamas has joined #zig
<satchmo> why am i disconnecting/connecting a million times everytime i put my laptop to sleep
shakesoda has joined #zig
<ikskuh> maybe your laptop wakes up some time
wozeparrot has joined #zig
Akuli has joined #zig
<satchmo> im sorry dave, i cannot disconnect from irc
<satchmo> that would be a bit unsettling
rzezeski has joined #zig
gazler_ has quit [Read error: Connection reset by peer]
gazler has joined #zig
Akuli has quit [Quit: Leaving]
Akuli has joined #zig
slowtype1 has joined #zig
slowtyper has quit [Ping timeout: 246 seconds]
dddddd has joined #zig
waleee-cl has quit [Quit: Connection closed for inactivity]
casaca has quit [Quit: leaving]
dermetfan has quit [Ping timeout: 272 seconds]
stripedpajamas has quit [Quit: sleeping...]
stripedpajamas has joined #zig
Snetry has quit [Ping timeout: 246 seconds]
Snetry has joined #zig
<companion_cube> watching the redis async/await talk
<companion_cube> andrewrk: I imagine suspend/resume is plenty enough to do safe recursion, by just pushing frames onto a heap-allocated stack, correct?
<fengb> It is possible yes
<fengb> Not very ergonomic
<companion_cube> still more ergonomic than no recursion
stripedpajamas has quit [Quit: sleeping...]
dermetfan has joined #zig
reductum has joined #zig
Snetry has quit [Ping timeout: 265 seconds]
alexnask has quit [Quit: Leaving]
Snetry has joined #zig
lanodan has quit [Ping timeout: 272 seconds]
casaca has joined #zig
dimenus has joined #zig
lanodan has joined #zig
stripedpajamas has joined #zig
satchmo has quit [Ping timeout: 260 seconds]
satchmo has joined #zig
satchmo has quit [Ping timeout: 246 seconds]
stripedpajamas has quit [Quit: sleeping...]
alexnask has joined #zig
<dimenus> andrewrk: did you ever create a github repo for your basic tcp server?
waleee-cl has joined #zig
bjorob has joined #zig
wootehfoot has quit [Ping timeout: 240 seconds]
<FireFox317> dimenus, he published it as a gist: https://gist.github.com/andrewrk/34c21bdc1600b0884a3ab9fa9aa485b8
<dimenus> FireFox317: thank you
lanodan has quit [Read error: Connection reset by peer]
<pmwhite> Is this a comptime bug, or am I doing something wrong? https://paste.sr.ht/%7Ephilipwhite/9c2b422ddb48a40c5c0f86896c6f4f96267605bc
wootehfoot has joined #zig
lanodan has joined #zig
<FireFox317> pmwhite, parseFloat returns a `!T`, so you are catching the error but then also using the if statement to unwrap the optional, but there is no optional
<pmwhite> But I'm putting `catch null` after the call to `parseFloat`.
<pmwhite> If I pull the condition expression into a statement like `const parsed = std.fmt.parseFloat(f32, string) catch null`, and use `parsed` as the condition, then the compiler is fine with it.
lanodan has quit [Read error: Connection reset by peer]
<ifreund> yeah that seems like a bug, i think that should be valid
<FireFox317> what if you do `@as(?f32, std.fmt.parseFloat(f32, string) catch null)`?
lanodan has joined #zig
<pmwhite> that complains about being unable to inline shiftLeft1, add, and shiftRight1 from std/fmt/parse_float.zig
<pmwhite> But it works if you add `comptime` to the `string` parameter.
<FireFox317> yeah then it should be possible indeed
<pmwhite> But adding `comptime` to that parameter does not fix the original snippet.
<pmwhite> Issue submitted.
<pmwhite> Oh wait, no extracting into a local variable doesn't work. Well stink.
<ifreund> not even if you do const foo: ?f64 = ...?
<ifreund> er, f32 rather
<pmwhite> That has the same issue as what FireFox317 suggested
slurpie has joined #zig
kradnoel has joined #zig
<pmwhite> I fixed it by doing what I should doing anyway which is getting rid of `catch null`, since if-else supports error unions anyway.
<ifreund> nice, good to know
dimenus has quit [Quit: WeeChat 2.8]
stripedpajamas has joined #zig
reductum has quit [Quit: WeeChat 2.8]
<FireFox317> andrewrk, i think you can consider #5461 as WIP. I'm looking at the llvm-ir that clang generates and it a bit different, however it does passes the parameters as separate paramaters to the llvm-function, so that idea seems okay :D
tdc has quit [Ping timeout: 246 seconds]
dimenus has joined #zig
stripedpajamas has quit [Quit: sleeping...]
bjorob has quit [Ping timeout: 240 seconds]
casaca has quit [Remote host closed the connection]
casaca has joined #zig
Akuli has quit [Quit: Leaving]
ur5us has joined #zig
satchmo has joined #zig
neceve has quit [Ping timeout: 264 seconds]
bjorob_ has joined #zig
stripedpajamas has joined #zig
satchmo has quit [Quit: WeeChat 2.8]
stripedpajamas has quit [Quit: sleeping...]
casaca has quit [Remote host closed the connection]
casaca has joined #zig
stripedpajamas has joined #zig
alexnask has quit [Quit: Leaving]
FireFox317 has quit [Ping timeout: 264 seconds]
stripedpajamas has quit [Quit: sleeping...]
stripedpajamas has joined #zig
kradnoel has quit [Read error: Connection reset by peer]
kradnoel has joined #zig
<fraktor> Where can I find documentation on how Traits work in zig?
<ifreund> zig doesn't have traits
<fraktor> What is in std/meta/trait.zig then?
<ifreund> ah, that's comptime introspection on types
<ifreund> i was thinking of traits in the rusty sense
<fraktor> Right. I know something that does vtable stuff is in the works, but traits are what we have for now.
<fraktor> *?
<ifreund> these are really related to vtables at all
casaca has quit [Remote host closed the connection]
<ifreund> it's just introspection, not a form of interface or polymorphism
<fraktor> I see.
<ifreund> *aren't really related <-- if it wasn't clear that was a typo :D
<fraktor> That's not unlike how Allocators work right now, correct?
<ifreund> no, though a little more genricized
<fraktor> Right. What advantage does this have over the way Allocator is implemented?
<ifreund> well, this tries to solve the general case rather than being a specific implementation
<ifreund> I haven't really dug in, ended up rolling my own version of polymorphism based on a tagged union for my project
_Vi has quit [Ping timeout: 260 seconds]
kradnoel has quit [Remote host closed the connection]
dermetfan has quit [Ping timeout: 260 seconds]
casaca has joined #zig
ifreund has quit [Ping timeout: 258 seconds]