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/
ofelas has joined #zig
stripedpajamas has quit [Quit: sleeping...]
aerona has joined #zig
<ifreund> mq32: is kristall GPL-3.0-or-later or GPL-3.0-only?
<ifreund> (packing for void)
<ifreund> hrm, i guess it is nearly 3am in germany, I shouldn't really expect an answer
<waleee-cl> are you making a template for river?
<ifreund> no, this is for https://github.com/MasterQ32/kristall
<ifreund> i will definitely package river for void when I do the first release
<ifreund> still a bit of work to do before I'm ready to do that though
<waleee-cl> ah, I read it as "is it kristall [clear] ..."
<waleee-cl> (it's 3am in Sweden too)
<ifreund> yeah I should really get to sleep (I'm also in germany)
keithdc has joined #zig
keithdc has quit [Read error: Connection reset by peer]
<marler8997> what is a "backward branch" when talking about @setEvalBranchQuota?
ur5us has quit [Ping timeout: 260 seconds]
<pixelherodev> andrewrk: so what's the conclusion?
<pixelherodev> How do you want the C backend to work?
ur5us has joined #zig
cole-h has joined #zig
cole-h has quit [Client Quit]
reductum has joined #zig
<aerona> Is it planned for TailQueue to be changed to a similar API as SinglyLinkedList?
Mulugruntz has joined #zig
reductum has quit [Quit: WeeChat 2.8]
dddddd has quit [Ping timeout: 260 seconds]
<daurnimator> aerona: huh? aren't they already quite similar?
stripedpajamas has joined #zig
<aerona> andrew removed init() and all the node helper functions: allocateNode, destroyNode, etc.
<aerona> not a big change but now they differ by that little bit
Mulugruntz has quit [Ping timeout: 240 seconds]
<andrewrk> pixelherodev, no progress today, I had to deal with a battery swelling issue. I'm on a backup laptop now, still setting up my environment
Mulugruntz has joined #zig
<daurnimator> misc idea: mem.readIntBig and friends could take `(comptime T: type, buf: *[@sizeOf(T)]const u8)`
<daurnimator> actually could it be: `buf: [@sizeOf(T)]u8`?
dimenus has quit [Ping timeout: 258 seconds]
<stripedpajamas> how do you do an anonymous list of anonymous structs
<stripedpajamas> i tried but got immediate segfault
<daurnimator> stripedpajamas: "list" meaning slice, array or tuple?
<stripedpajamas> slice
<daurnimator> either take the address of an array of them, or allocate some room...
<stripedpajamas> oh i may have meant array
<stripedpajamas> i'm trying to do just a list of test cases
<stripedpajamas> with input/expected structs
<stripedpajamas> anonymously
<daurnimator> you're going to need to share some code
<stripedpajamas> const testCases = .{ .{ .input = "asdf", .expected = "fdsa", }, .{ .input = "xyzz", .expected = "zzyx", } };
<stripedpajamas> something like that in a test block
<stripedpajamas> where i can then loop over test cases and call e.g. a reverse func on input and assert it is expected
<stripedpajamas> oh actually that example works fine
<pixelherodev> andrewrk: oof, ouch
<pixelherodev> Should I just focus on the internals and leave the frontend for later?
<pixelherodev> I could add a temporary test harness I suppose
<pixelherodev> and use that to work on it
<stripedpajamas> daurnimator: opened this https://github.com/ziglang/zig/issues/5764
<pixelherodev> I'm going to be away from Zig for a few days as well, most likely
<pixelherodev> I sorta borked my main install, and I
<pixelherodev> 'm working on fixing it still
<pixelherodev> I borked it on purpose though
<pixelherodev> Wiping out PAM, as was mentioned elsewhere :P
cole-h has joined #zig
<pixelherodev> And now I"m going for broke and wiping elogind and polkit too
<pixelherodev> Remove all the crap in one go
waleee-cl has quit [Quit: Connection closed for inactivity]
gpanders has quit [Ping timeout: 256 seconds]
gpanders has joined #zig
aerona has quit [Quit: Leaving]
stripedpajamas has quit [Quit: sleeping...]
ur5us has quit [Ping timeout: 240 seconds]
stripedpajamas has joined #zig
stripedpajamas has quit [Quit: sleeping...]
dermetfan has joined #zig
dermetfan has quit [Ping timeout: 260 seconds]
marnix has joined #zig
dermetfan has joined #zig
cole-h has quit [Quit: Goodbye]
ur5us has joined #zig
ur5us_ has joined #zig
ur5us has quit [Ping timeout: 260 seconds]
ur5us_ has quit [Ping timeout: 265 seconds]
marnix has quit [Ping timeout: 265 seconds]
nikita` has joined #zig
alexnask has joined #zig
penguinicus has quit [Remote host closed the connection]
_Vi has joined #zig
_whitelogger has joined #zig
yeti has quit [Ping timeout: 264 seconds]
yeti has joined #zig
dingenskirchen has quit [Quit: dingenskirchen]
dingenskirchen has joined #zig
dingenskirchen has quit [Client Quit]
dingenskirchen has joined #zig
<pixelherodev> andrewrk: don't you just *hate* practicality? :P
<andrewrk> haha
<andrewrk> good night
<pixelherodev> Night!
<ifreund> night o7
<pixelherodev> andrewrk: real quick, what was the resulting RSS usagae?
<pixelherodev> usage*
<andrewrk> 5.14 GiB => 5.13 GiB
<pixelherodev> lol
<pixelherodev> that's still pretty bad
<pixelherodev> ... I'd look into it but
<pixelherodev> stage1 scares me
<pixelherodev> a lot
<andrewrk> it's mostly unfreed ZigValues
<pixelherodev> Would fixing that be a major rework?
<pixelherodev> Or can they be fixed incrementally?
<andrewrk> yes it would be a huge undertaking
<pixelherodev> Not it
<andrewrk> I've solved it in self-hosted
<pixelherodev> I already need to fix the things I broke when fixing memory leaks in scas lol
<pixelherodev> And scas is tiny compared to stage1
<pixelherodev> 9K LoC lol
<yeti> hi! which triple (for the bootstrap) would match an A20 (armhf, arm7l)?
<andrewrk> yeti, use `-mcpu=generic+help` and it will print some helpful options for you
<yeti> thanks, I'll look
<andrewrk> zig build-exe foo.zig -target arm-freestanding -mcpu=generic+help
<yeti> would arm-linux-musleabi cortex_a7 as args for bootstrap make sense?
<yeti> (a cubietruck)
<scientes> yeti, musleabihf
<yeti> yip... gcc has that eabihf in the triple too
<yeti> \o/
<yeti> I'll try a bootstrap with it
frmdstryr has quit [Ping timeout: 246 seconds]
ofelas has quit [Ping timeout: 240 seconds]
ofelas has joined #zig
<rooke> Due to the current c abi limitations I have written a tiny function in c to be called by zig. What's the easiest way to call that function?
<scientes> rooke, probably @cImport @cInclude
<scientes> rooke, it will tell you if you hit the limitations
Cadey has quit [Ping timeout: 246 seconds]
<ifreund> ^ this and addCSourceFile() in your build.zig
Cadey has joined #zig
<rooke> I think that last step is what I was missing, it complained about not being able to find the c file
<ifreund> there's two parts there, you need to addIncludeDir() so it can find the header and addCSourceFile() so it compiles the object
rooke has quit [Ping timeout: 256 seconds]
rooke has joined #zig
losinggeneration has quit [Ping timeout: 260 seconds]
layneson has joined #zig
anton_lilja has joined #zig
layneson has quit [Ping timeout: 246 seconds]
anton_lilja has quit [Quit: Leaving]
Ziemas has quit [Ping timeout: 260 seconds]
layneson has joined #zig
nerthus has quit [Quit: bye]
waleee-cl has joined #zig
jmiven has quit [Quit: reboot]
jmiven has joined #zig
nikita` has quit [Quit: leaving]
frmdstryr has joined #zig
layneson has quit [Ping timeout: 260 seconds]
layneson has joined #zig
ask6155 has joined #zig
<ask6155> Hello
<mq32> Hi
<alexnask> hi
<fengb> Hi
<pixelherodev> Salutations, human!
<marler8997> I asked this yesterday but maybe someone knows the answer today, anyone know what a "backwards branch" is when talking about @setEvalBranchQuota?
<pixelherodev> Presumably, a branch that goes backwards
<pixelherodev> e.g.
<pixelherodev> `a: b(); c(); goto a;`
<pixelherodev> `goto a` => backwards branch
<ask6155> So I was thinking of using notcurses in my zig project to make some cool terminal programs. How should I go about doing some cool stuff in the most coolest way? (Remember coolness is more important) I had an idea. Get the code compile the library statically using the zig compiler with musl as libc (If that makes any sense) and then statically link it to my (cool) zig program. Can it get any more cooler?
<pixelherodev> I mean
<pixelherodev> static compilation with musl is trivial with Zig
<pixelherodev> Just `--library c --target x86_64-linux-musl` for instance
Mulugruntz has quit [Ping timeout: 240 seconds]
Mulugruntz has joined #zig
Akuli has joined #zig
<ask6155> yeah so can it get any cooler? I wan to make it leet h3cker xxX_program_Xxx
<alexnask> write it in kakoune
<fengb> Most cool = no libc. Gotta write a curses library
<ifreund> kakoune has a branch with no ncurses support
<ifreund> er, no ncurses cause he implemented builtin terminal stuff
<ifreund> just gotta rewrite kak in zig
penguinicus has joined #zig
penguinicus has quit [Remote host closed the connection]
penguinicus has joined #zig
layneson has quit [Ping timeout: 256 seconds]
ask6155 has left #zig ["k-byeeeee"]
dingenskirchen has quit [Remote host closed the connection]
dingenskirchen has joined #zig
craigo has joined #zig
knebulae has quit [Read error: Connection reset by peer]
craigo has quit [Quit: Leaving]
craigo has joined #zig
craigo has quit [Client Quit]
a_chou has joined #zig
a_chou has quit [Remote host closed the connection]
craigo has joined #zig
a_chou has joined #zig
a_chou has quit [Client Quit]
rooke has quit [Ping timeout: 258 seconds]
rooke has joined #zig
marler8997 has quit [*.net *.split]
bbrittain has quit [*.net *.split]
ave_ has quit [*.net *.split]
benaiah has quit [*.net *.split]
meowray has quit [*.net *.split]
bens has quit [*.net *.split]
JoshAshby has quit [*.net *.split]
benaiah has joined #zig
\u has joined #zig
bbrittain has joined #zig
ifreund has quit [*.net *.split]
tgschultz has quit [*.net *.split]
hspak has quit [*.net *.split]
Amun_Ra has quit [*.net *.split]
tgschultz has joined #zig
ifreund has joined #zig
Amun_Ra has joined #zig
hspak has joined #zig
nmeum has quit [Remote host closed the connection]
drewr has quit [Ping timeout: 240 seconds]
nmeum has joined #zig
knebulae has joined #zig
drewr has joined #zig
ofelas has quit [Ping timeout: 240 seconds]
linuxgemini has quit [Quit: o/ https://thelounge.lasagna.dev]
ofelas has joined #zig
penguinicus has quit [Remote host closed the connection]
penguinicus has joined #zig
linuxgemini has joined #zig
penguinicus has quit [Remote host closed the connection]
dingenskirchen has quit [Remote host closed the connection]
dingenskirchen has joined #zig
<shcv> PackedIntIo isn't exposed by std; how do I load it?
<shcv> or do I need to copy the pieces I need into my library?
nikita` has joined #zig
<leeward> std.packed_int_array.PackedIntIo
cole-h has joined #zig
frmdstryr has quit [Ping timeout: 258 seconds]
stripedpajamas has joined #zig
bgiannan has quit [*.net *.split]
bsrd has quit [*.net *.split]
bgiannan has joined #zig
<tgschultz> shcv: I'm curious why you need to access PackedIntoIo directly, since it was designed just as a way to share a bunch of code between the various PackedIntArray/Slice implementations.
<shcv> I think I'll probably need to implement my own variant, but I wanted to test with it some first
<fengb> I used it directly in WasmPageAllocator. Saved a few bytes over using a PackedIntSlice
<shcv> I want to be able to get chunks out of an array that may not be an even multiple of the chunk size
<shcv> the odds of actually needing to retrieve the last few bits are very low, but it would be nice to handle that case with truncation
marler8997 has joined #zig
ur5us_ has joined #zig
ofelas has quit [Ping timeout: 260 seconds]
ofelas has joined #zig
<shcv> does branch prediction normally assume the if rather than the else?
<pixelherodev> Hardware-dependent.
<pixelherodev> There's no real way to answer that
<fengb> It's both compiler and hardware dependent
<fengb> So... no not really?
Akuli has quit [Quit: Leaving]
<mq32> self.items.len = self.capacity;
<mq32> i … didn't know that this was allowed
<mq32> i am shocked
<fengb> Back to mq32?
<pixelherodev> lol
<mq32> fengb: happens from time to time
mq32 is now known as ikskuh
<ikskuh> problem is: mq32 is owner of a channel here, i have to log in with this nick :D
nikita` has quit [Quit: leaving]
ofelas has quit [Ping timeout: 260 seconds]
ofelas has joined #zig
dermetfan has quit [Ping timeout: 260 seconds]
<ifreund> alexnask: wow you get a lot of "I can't compile zls cause I'm using 0.6.0" issues :D
<alexnask> Yeah :p
alexnask has quit [Quit: Leaving]
\u is now known as meowray
ofelas has quit [Ping timeout: 260 seconds]
dingenskirchen has quit [Remote host closed the connection]
<andrewrk> I can't believe the complete rewrite of HashMap had basically zero impact on any perf or memory issues
<ifreund> :(
ofelas has joined #zig
ofelas has quit [Ping timeout: 260 seconds]
layneson has joined #zig
ofelas has joined #zig
ofelas has quit [Ping timeout: 260 seconds]
ofelas has joined #zig
ofelas has quit [Ping timeout: 260 seconds]
layneson has quit [Ping timeout: 272 seconds]