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/
reductum has quit [Quit: WeeChat 2.9]
ur5us_ has quit [Ping timeout: 264 seconds]
jjsullivan1 has joined #zig
<daurnimator> g-w1: not so much frontends as plugins
<g-w1> tysm. it enables a modern line interface that i have been missing
Jeanne-Kamikaze has joined #zig
frmdstryr has joined #zig
radgeRayden has joined #zig
lltt has quit [Ping timeout: 256 seconds]
Jeanne-Kamikaze has quit [Remote host closed the connection]
<g-w1> could someone take a look at my pr https://github.com/ziglang/zig/pull/7092, especially in zir_sema.analyzeInstMergeErrorSets. I tried to use the same strategy at analyzeInstErrorSet, but it makes the type a Pointer instead of a Type
<g-w1> I also have no clue if im writing good/idomatic stage2 code, so it would be nice to know before moving on and doing more stuff
kristoff_it has quit [Ping timeout: 244 seconds]
marceco has joined #zig
marceco has quit [Remote host closed the connection]
moinstar has joined #zig
mmohammadi9812 has quit [Ping timeout: 256 seconds]
mmohammadi9812 has joined #zig
a_chou has joined #zig
xackus_ has joined #zig
xackus has quit [Ping timeout: 256 seconds]
a92 has quit [Quit: My presence will now cease]
earnestly has quit [Ping timeout: 240 seconds]
ky0ko has quit [Remote host closed the connection]
gert_ has quit [Quit: WeeChat 2.9]
ky0ko has joined #zig
a_chou has quit [Ping timeout: 272 seconds]
oats is now known as cosmic-sans
aerona has quit [Ping timeout: 264 seconds]
a_chou has joined #zig
Kingsquee has joined #zig
<dominikh> has anyone gotten Tracy's callstack capture to work with Zig? the only stack frame it's capturing for me is the tracy instrumentation function itself, none of Zig's callstack. I'm not sure if it can be expected to work, though.
frmdstryr has quit [Ping timeout: 240 seconds]
mmohammadi9812 has quit [Quit: Quit]
lltt has joined #zig
jjsullivan has quit [Remote host closed the connection]
waleee-cl has quit [Quit: Connection closed for inactivity]
a_chou has quit [Ping timeout: 256 seconds]
_whitelogger has joined #zig
ky0ko has quit [Read error: Connection reset by peer]
ky0ko has joined #zig
ky0ko has quit [Remote host closed the connection]
ky0ko has joined #zig
<pixelherodev> dominikh: Tracy in zig is only for stage2 I think?
<pixelherodev> Unless you mean in your own program
<pixelherodev> In which case I have noooo clue
<dominikh> yeah, in my own program.
<dominikh> I have absolutely no idea how stack frames are represented in Zig, but I guess they're different enough from C
<pixelherodev> dominikh: check how stage2 does it?
<pixelherodev> It's definitely possible
<pixelherodev> The compiler uses it
<pixelherodev> src/tracy.zig I believe
<dominikh> does it actually successfully capture stack traces for zones? you can get _most_ of tracy to work relatively easy, yeah
<pixelherodev> Ah, stack traces... no idea
<pixelherodev> Could be
<pixelherodev> andrewrk would know, I believe
<pixelherodev> You can always check
a_chou has joined #zig
knebulae has quit [Read error: Connection reset by peer]
marnix has joined #zig
marnix has quit [Read error: Connection reset by peer]
marnix has joined #zig
a_chou has quit [Quit: a_chou]
jjsullivan has joined #zig
_whitelogger has joined #zig
cole-h has quit [Ping timeout: 264 seconds]
decentpenguin has quit [Read error: Connection reset by peer]
decentpenguin has joined #zig
osa1 has quit [Quit: osa1]
<dominikh> well, I can't get stage 2 to build with tracy enabled, and since it looks like a C++ issue, I'm not going to dig further :) I'm pretty sure zig isn't doing anything more to integrate Tracy than I am, anyway
osa1 has joined #zig
remal has left #zig [#zig]
xackus_ has quit [Ping timeout: 246 seconds]
lltt has quit [Ping timeout: 260 seconds]
_whitelogger has joined #zig
ifreund has quit [Ping timeout: 260 seconds]
marnix has quit [Ping timeout: 260 seconds]
marnix has joined #zig
ur5us_ has joined #zig
xackus_ has joined #zig
ifreund has joined #zig
ifreund has quit [Ping timeout: 260 seconds]
neceve has joined #zig
ifreund has joined #zig
earnestly has joined #zig
gpanders has quit [Quit: ZNC - https://znc.in]
gpanders has joined #zig
ur5us_ has quit [Ping timeout: 264 seconds]
knebulae has joined #zig
hnOsmium0001 has quit [Quit: Connection closed for inactivity]
lltt has joined #zig
Kingsquee has quit []
<dominikh> idiomatically, if a function can only succeed or fail, and doesn't differentiate between kinds of errors, and otherwise returns void, should it return a !void or a bool?
tane has joined #zig
<daurnimator> !void probably
<dominikh> been leaning towards that, too
haliucinas has quit [Remote host closed the connection]
haliucinas has joined #zig
marnix has quit [Read error: Connection reset by peer]
marnix has joined #zig
skuzzymiglet has joined #zig
kristoff_it has joined #zig
<dominikh> http://sprunge.us/00azQ0 why is this considered a redeclaration?
<dominikh> is it the same, rather strict, "no shadowing" rule?
xackus_ has quit [Ping timeout: 272 seconds]
xackus_ has joined #zig
riba has joined #zig
amk has quit [Remote host closed the connection]
amk has joined #zig
cosmic-sans is now known as oats
riba has quit [Ping timeout: 246 seconds]
<g-w1> yes it is. consider this `const x = 10; pub fn main() {const x = 10;}` it is the same thing
<g-w1> the upper x is visible from the function namespace, so it can't be refedined
waleee-cl has joined #zig
<dominikh> fair
lltt has quit [Ping timeout: 264 seconds]
skuzzymiglet has quit [Read error: Connection reset by peer]
<viaken> Beginner question: How do I catenate a string literal and text I've brought in at runtime (of type []u8)?
<waleee-cl> viaken: https://ziglang.org/documentation/master/#Arrays see the lines after //rememver that string literals are arrays
<waleee-cl> (tldr: ++)
<g-w1> i think they want to concatonate at runtime, so ++ wont work
<waleee-cl> ah, ok
<g-w1> viaken, what you probably want to do is to allocate a slice of the compile time slice plus the runtime slice, then copy the compile time slice into it and the runtime slice after the compile time slice
<ifreund> std.mem.concat?
<g-w1> ig you could also do that. i didn't know about that :P
<viaken> I'll have to concatenate at runtime, yeah. It's a little hook util that takes an argument and then adds the argument to a message it passes to a different util.
cole-h has joined #zig
<viaken> Thank you all
xackus_ has quit [Ping timeout: 246 seconds]
<yZ5vlALg86lP> i was wondering are any members of the core team residents of the EU? preferably from ex-socialist countries?
<waleee-cl> that was specific
riba has joined #zig
lucid_0x80 has joined #zig
<pixelherodev> Weirdly specific :P
<CommunistWolf> my kind of specific
<yZ5vlALg86lP> well there is some eu money to be dispensed, but the pool is overwhelmed by western countries, and in the interest of balance eastern countries are prefered.
<CommunistWolf> I should've gotten that estonian e-residency after all
frmdstryr has joined #zig
osa1 has quit [Quit: osa1]
osa1 has joined #zig
Akuli has joined #zig
riba has quit [Ping timeout: 264 seconds]
Jeanne-Kamikaze has joined #zig
frmdstryr has quit [Ping timeout: 256 seconds]
hnOsmium0001 has joined #zig
cren has joined #zig
frmdstryr has joined #zig
frmdstryr has quit [Ping timeout: 260 seconds]
cren has quit [Quit: cren]
xackus_ has joined #zig
wootehfoot has joined #zig
radgeRayden_ has joined #zig
radgeRayden has quit [Ping timeout: 272 seconds]
reductum has joined #zig
skuzzymiglet has joined #zig
skuzzymiglet has quit [Client Quit]
skuzzymiglet has joined #zig
skuzzymiglet has quit [Client Quit]
skuzzymiglet has joined #zig
moo has joined #zig
skuzzymiglet has quit [Client Quit]
skuzzymiglet has joined #zig
wootehfoot has quit [Ping timeout: 256 seconds]
radgeRayden_ has quit [Read error: Connection reset by peer]
neceve has quit [Ping timeout: 256 seconds]
techtirade_ has quit [Ping timeout: 260 seconds]
bodie_ has quit [Ping timeout: 260 seconds]
techtirade has joined #zig
sergeeeek[m]1 has quit [Ping timeout: 260 seconds]
gpanders[m] has quit [Ping timeout: 260 seconds]
josias has quit [Ping timeout: 260 seconds]
ugla has quit [Ping timeout: 260 seconds]
ugla has joined #zig
josias has joined #zig
bodie_ has joined #zig
bodie_ has joined #zig
bodie_ has quit [Changing host]
sergeeeek[m]1 has joined #zig
gpanders[m] has joined #zig
Jeanne-Kamikaze has quit [Ping timeout: 246 seconds]
lucid_0x80 has quit [Ping timeout: 260 seconds]
ur5us_ has joined #zig
Jeanne-Kamikaze has joined #zig
squeek502 has joined #zig
<Snektron> alexnask lives in greece
<Snektron> althought thats probably not ex socialist
<alexnask[m]> Yeah : p
<alexnask[m]> Ive heard some Americans describe as as a socialist country along with Venezuela to blame our economic crisis on socialism
<alexnask[m]> Always gives me a good chukle
<alexnask[m]> s/as as/us as/g
moo has quit [Read error: Connection reset by peer]
cren has joined #zig
<alexnask[m]> But anyway, Jakub (kubkon) and Veikka (vexu) are also core members in the EU I believe
<pixelherodev> alexnask[m]: My apologies for the stupidity of most of countrymen :P
<pixelherodev> s/coun/my &/
frmdstryr has joined #zig
cren has quit [Quit: cren]
marnix has quit [Ping timeout: 260 seconds]
GuerrillaMonkey has joined #zig
Jeanne-Kamikaze has quit [Ping timeout: 260 seconds]
riba has joined #zig
<betawaffle> pixelherodev: oh, that's why
<pixelherodev> betawaffle: :)
xackus_ has quit [Ping timeout: 265 seconds]
Akuli has quit [Quit: Leaving]
riba has quit [Ping timeout: 260 seconds]
lltt has joined #zig
hlolli has joined #zig
<hlolli> Hi all, I've had my eyes on zig for few months, but never actually tried to learn it. Until recently. The cross compiling feature is amazing. Anyway, I'm trying to make developing bit easier, I'm not finding easy to use print statements, but analyzing other zig code I stumbled on this https://github.com/Vexu/bog/blob/master/src/std/io.zig I was curious if this files will actually add "print" to std.io namespace?
<g-w1> it seems that this is the standard library of vexu's bog programming language. this doesn't affect zig's standard library at all. if you could give an example of where printing something was hard, i think the community could help you
<g-w1> hlolli
<betawaffle> to start with, what are you trying to print, hlolli?
<hlolli> thanks, I realize in bog's example it makes total sense, using std.log.info is fine as well as I don't need to catch it. In comparison to const stdout = std.io.getStdOut().writer(); stdout.print("somelog\n", .{}) catch unreachable;, it's a bit nicer. But a printing arrays or hashmaps, I'd be happy if there was a snippet for printing various datatypes, but this is no blocker.
<g-w1> well you could make wrapper functions to view data structures (iterating through hashmap). iirc though, std.fmt can print structs and maybe arrays
<hlolli> ah nice ok! didn't know. Exactly, wrapper functions. Related or unrelated to this, are there any zig libraries with helper/wrapper goodies for development. I notice on the website, the community projects are only "end product". In a good way, zig seems to offer a lot of customizations and seems to leave sugars to the user, which makes me wonder if there's a list of projects somewhere I didn't see.
<waleee-cl> hlolli: there's https://github.com/ziglibs which collects some
<hlolli> bingo exactly, thanks :)
<waleee-cl> this repo on it https://github.com/ziglibs/repository has a "list" in the 'packages' directory
<waleee-cl> hlolli: ... and you have the corresponding https://github.com/zigtools/ (which you might have seen if you have installed zls)
<hlolli> nice nice, I already have emacs package running, very nice. I'll bookmark these two and try to get zpm running. I was also scratching my head over if there was any package management in the language. Seems like there is.
<g-w1> no official yet
skuzzymiglet has quit [Ping timeout: 265 seconds]
ur5us_ has quit [Ping timeout: 264 seconds]
adamkowalski has joined #zig
<adamkowalski> Is there a way to check for a compile error in a unit test?
<adamkowalski> I have some compile time checks that should prevent a certain class of domain specific bugs
<adamkowalski> and I want to unit tests my compile time checks
tane has quit [Quit: Leaving]
<pfg_> adamkowalski, not right now unfortunately. I had to redo lots of my comptime stuff to return compile errors out so I could test them in unit tests.
ur5us_ has joined #zig
<adamkowalski> Yeah I ended up doing something similar
<adamkowalski> rather than checking for the compile error directly
<adamkowalski> extract the checker into a function and then assert that it evaluates to false, and returns the correct message
<adamkowalski> but now that it is working, it feels incredible. I can't believe I can check all this stuff at compile time, and my types encode all the information they need so that they are "impossible" to misuse