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/
<v0idify> sadge
<v0idify> i would leave it even if it's outdated for people who might come with some zig code that's older and applies to it, i think it's an important page to have
n0tekky has joined #zig
mikdusan1 has joined #zig
mikdusan has quit [Ping timeout: 246 seconds]
gazler_ has joined #zig
gazler has quit [Ping timeout: 260 seconds]
craigo has quit [Ping timeout: 256 seconds]
karrick has joined #zig
<karrick> Has anyone built Zig compiler using MacPorts before?
marler8997 has joined #zig
<karrick> in other words, by using something along the lines of `cmake .. -DCMAKE_PREFIX_PATH=/opt/local -DCMAKE_PROGRAM_PATH=/opt/local/libexec`
n0tekky has quit [Read error: Connection reset by peer]
Thalheim has joined #zig
<karrick> Never mind. I am making progress, so I am on the right path.
jicksaw has quit [Quit: ZNC is kill]
jukan has joined #zig
jicksaw has joined #zig
jukan_ has quit [Ping timeout: 256 seconds]
reductum has quit [Quit: WeeChat 3.0]
reductum has joined #zig
reductum has quit [Client Quit]
osa1 has quit [Ping timeout: 264 seconds]
<andrewrk> chances looking good I'll get zig building again in ast-memory-layout branch tonight
<andrewrk> after that, remaining tasks are: fix whatever regressions happened, fix remaining zig fmt test cases, and get vexu's translate-c branch landed (#7479)
<g-w1> oh nice you factored all the builtin boilerplate out.
forgot-p1ssword has joined #zig
forgot-password has quit [Ping timeout: 256 seconds]
<andrewrk> it's cool that this non-master branch has 4 contributors in it other than me
<andrewrk> really appreciate the group effort here
<karrick> How many folks here build zig compiler on Mac? I tried using MacPorts' version of LLVM, Clang, but running into build issues because libraries and headers do not have matching paths in the Findclang.cmake and friends. I am now just going to skip MacPorts and just build the entire LLVM, Clang myself...
<andrewrk> karrick, last I checked it worked fine with llvm, clang, lld from homebrew
<andrewrk> building them from source yourself is always an option though
<karrick> Thanks; if plan B does not work, I have a plan C in standby
xackus_ has joined #zig
xackus__ has joined #zig
xackus has quit [Ping timeout: 265 seconds]
xackus_ has quit [Ping timeout: 256 seconds]
<mikdusan1> what macos version?
<karrick> Big Sur 11.2.1
<mikdusan1> arm64 ?
<karrick> I used to MacPorts back when Darwin first came out in early 2000s, but switched to home brew a number of years ago when they had newer ports. Decided to give MacPorts another try actually earlier today, and decided to give building Zig a whirl using it.
<karrick> No, I'm on a 2.4 GHz 8-Core Intel Core i9 with 32 GiB. This is going to take a while...
<karrick> Are you building on the newer M1 chip?
<andrewrk> about an hour, usually
<mikdusan1> fyi today macports has `clang-11` and `llvm-11` which are based on 11.0.1 sources. But careful, macports may decide to bump to 11.1.0. I don't know what their policy is on that.
<karrick> Hm, I am actually building against llvm-11 on HEAD... So maybe this is just a test run and won't work...
<mikdusan1> if building from llvm-project sources use tag llvmorg-11.0.1 ; zig's next _planned_ bump will be llvmorg-12.0.0 . don't use any changing branches
<mikdusan1> s/changing/tracking/
<karrick> thanks
<mikdusan1> if you hit a snag, I just put up some bins for another dev, and look at the 01-command_line_log.sh, I captured all the "exec" done from my build script,
<mikdusan1> and the main goal of building this way was to NOT use macports or brew. basically all that should be needed is xcode, a cmake binary, llvm-project
<mikdusan1> ah ok
<karrick> just saw your google drive link. Taking a look...
dputtick has quit [Ping timeout: 268 seconds]
dputtick has joined #zig
<karrick> So is this a sub-project effort of Zig to minimize build time dependencies? I'm wondering whether porting to openbsd would be feasible? I'm sure the compiler can be easily ported, but the real work is upgrading the Zig standard library to work with OpenBSD-isms...
<mikdusan1> I am unsure of what "sub-project" is?
mikdusan1 is now known as mikdusan
<karrick> I don't have a formal definition of "sub-project." Just wondering whether this is a concerted effort to reduce the build time dependencies for easier porting.
<karrick> Are you capturing your build scripts in a github repos?
<karrick> Or just in this shared directory structure with output blobs?
<mikdusan> if I get your meaning, then not really. Any platform needs to supply those deps. Sometimes people work together and share those deps amongst themselves.
jukan has quit [Quit: leaving]
<braket> lmao, randomly seeing a u29 just chilling as some parameter's type in stdlib has got to be one of the funniest thing I've ever seen.. Zig is just too cool lol
<karrick> gotta save those extra bits for when you might need them... ;)
<mikdusan> zig already has `zig-bootstrap` repo. but yeah, my custom scripts are git'd
<karrick> ooh, I need to take a look at zig-bootstrap. Thank you!
<daurnimator> braket: u29 is used for alignment, because that's what LLVM does. though IMO it doesn't make sense
<daurnimator> there are CPUs that exist with higher alignment requirements
<braket> ahh i see. but what a random number 29 is though; like it just *looks* random lol
earnestly has quit [Ping timeout: 246 seconds]
CodeSpelunker has joined #zig
forgot-p1ssword has quit [Read error: Connection reset by peer]
remby has joined #zig
forgot-password has joined #zig
CodeSpelunker has quit [Quit: CodeSpelunker]
remby has quit [Quit: remby]
remby has joined #zig
remby has quit [Quit: remby]
remby has joined #zig
Techcable has quit [Remote host closed the connection]
osa1 has joined #zig
dongcarl has quit [Quit: Ping timeout (120 seconds)]
dongcarl has joined #zig
forgot-password has quit [Ping timeout: 240 seconds]
forgot-password has joined #zig
forgot-password has quit [Ping timeout: 264 seconds]
_whitelogger has joined #zig
<andrewrk> woot, got zig building finally in the ast-memory-layout branch
<andrewrk> I wonder how many regressions there are
decentpenguin has quit [Read error: Connection reset by peer]
decentpenguin has joined #zig
cole-h has quit [Ping timeout: 246 seconds]
midgard has joined #zig
midgard_ has quit [Ping timeout: 256 seconds]
<andrewrk> posted a zig fmt benchmark for this branch: https://github.com/ziglang/zig/pull/7920#issuecomment-781888503
sord937 has joined #zig
remby has quit [Quit: remby]
sord937 has quit [Ping timeout: 268 seconds]
<ifreund> andrewrk: nice work! \o/
<ifreund> I should have some more time for zig fmt over the weekend
sord937 has joined #zig
<andrewrk> sweet! I'll work on stage2 test case regressions in the meantime
craigo has joined #zig
xackus has joined #zig
xackus__ has quit [Ping timeout: 240 seconds]
kameliya[m] has quit [*.net *.split]
larme has quit [*.net *.split]
jicksaw has quit [Ping timeout: 264 seconds]
jicksaw has joined #zig
kameliya[m] has joined #zig
larme has joined #zig
hamoko[m] has quit [Ping timeout: 240 seconds]
pafmaf[m] has quit [Ping timeout: 240 seconds]
BitPuffin has quit [Ping timeout: 240 seconds]
Snektron has quit [Ping timeout: 240 seconds]
kameliya[m] has quit [Ping timeout: 258 seconds]
Nypsie[m] has quit [Ping timeout: 250 seconds]
mtiljeset[m] has quit [Ping timeout: 246 seconds]
fengb has quit [Ping timeout: 250 seconds]
dvaun has quit [Ping timeout: 250 seconds]
posixlix has quit [Ping timeout: 244 seconds]
watzon has quit [Ping timeout: 244 seconds]
vazub[m] has quit [Ping timeout: 244 seconds]
siraben has quit [Ping timeout: 244 seconds]
ifreund_ has quit [Ping timeout: 268 seconds]
tyrion-mx has quit [Ping timeout: 265 seconds]
ugla has quit [Ping timeout: 265 seconds]
tjammer[m] has quit [Ping timeout: 240 seconds]
xackus_ has joined #zig
xackus has quit [Ping timeout: 256 seconds]
DarkUranium has quit [Quit: ZNC 1.8.2 - https://znc.in]
DarkUranium has joined #zig
ugla has joined #zig
dtz has joined #zig
BitPuffin has joined #zig
hamoko[m] has joined #zig
ifreund_ has joined #zig
kameliya[m] has joined #zig
siraben has joined #zig
Snektron has joined #zig
Nypsie[m] has joined #zig
pafmaf[m] has joined #zig
mtiljeset[m] has joined #zig
vazub[m] has joined #zig
fengb has joined #zig
tjammer[m] has joined #zig
posixlix has joined #zig
proteusguy has quit [Remote host closed the connection]
riba has joined #zig
forgot-password has joined #zig
riba has quit [Ping timeout: 240 seconds]
hnOsmium0001 has quit [Quit: Connection closed for inactivity]
forgot-password has quit [Ping timeout: 240 seconds]
forgot-password has joined #zig
Swahili has joined #zig
earnestly has joined #zig
forgot-password has quit [Quit: leaving]
zags has joined #zig
proteusguy has joined #zig
dputtick has quit [Remote host closed the connection]
nikki93 has quit [Remote host closed the connection]
dch has quit [Remote host closed the connection]
dch has joined #zig
dch has quit [Remote host closed the connection]
dch has joined #zig
nikki93 has joined #zig
dputtick has joined #zig
jzelinskie has quit [Remote host closed the connection]
ovf has quit [Remote host closed the connection]
jzelinskie has joined #zig
ovf has joined #zig
ovf has quit [Excess Flood]
ovf has joined #zig
tnorth has joined #zig
jzelinskie has quit []
ovf has quit []
jzelinskie has joined #zig
ovf has joined #zig
gpanders has quit [Quit: ZNC - https://znc.in]
gpanders has joined #zig
Swahili has quit [Remote host closed the connection]
Snaffu has joined #zig
tnorth has quit [Ping timeout: 260 seconds]
jokoon has joined #zig
remby has joined #zig
mmohammadi9812 has joined #zig
mmohammadi9812 has quit [Max SendQ exceeded]
mmohammadi9812 has joined #zig
mmohammadi9812 has quit [Read error: Connection reset by peer]
mmohammadi9812 has joined #zig
mmohammadi9812 has quit [Remote host closed the connection]
jokoon has quit [Quit: Leaving]
kaun_ has joined #zig
kaun_ has left #zig [#zig]
jokoon has joined #zig
Swahili has joined #zig
donniewest has joined #zig
<zags> what's the idiomatic "pointer to anything, I'll cast you later" in zig? I have a rare instance of needing the equivalent of void*
<ifreund> zags: probably [*]u8
<ifreund> be careful about alignment of course
<zags> Well, this is a field that holds pointer to anything. What it is, is encoded elsewhere. So when I set the field, I'll ptrcast something that's correctly aligned already, no?
<zags> Same when casting back, wouldn't the alignment be correct?
<ifreund> indeed
<zags> wait, maybe usize is the right thing? That's what @frameAddress, etc returns
<ifreund> oh yeah usize is also a good choice
<zags> alright, thanks (again!)
dtz has quit [Quit: Idle for 30+ days]
<ifreund> [*]u8 is more if you want to slice it
<zags> ah right
<ifreund> usize is what I translate user_data void pointers to for zig-wlroots
<ifreund> (well, the ones I can't nicely abstract over that is)
jbou has quit [Quit: WeeChat 2.3]
remby has quit [Quit: remby]
remby has joined #zig
remby has quit [Quit: remby]
<v0idify> is there a helper to read until a character/newline and alloc for File?
<dutchie> io.Reader.readUntilDelimiterAlloc
<v0idify> yeah sorry i just realized
<dutchie> dw
ky0ko1 has quit [Ping timeout: 260 seconds]
cole-h has joined #zig
Snektron has quit [Ping timeout: 240 seconds]
Nypsie[m] has quit [Ping timeout: 240 seconds]
Snektron has joined #zig
fengb has quit [Ping timeout: 240 seconds]
fengb has joined #zig
<v0idify> i'm still getting EOF after seeking when reading a file, what should I do?
zags has quit [Ping timeout: 272 seconds]
ky0ko1 has joined #zig
Nypsie[m] has joined #zig
Akuli has joined #zig
sord937 has quit [Ping timeout: 268 seconds]
sord937 has joined #zig
mokafolio has quit [Quit: Bye Bye!]
mokafolio has joined #zig
craigo_ has joined #zig
isolier2 has joined #zig
nickster2 has joined #zig
m6w6_ has joined #zig
washbear has joined #zig
m6w6 has quit [Ping timeout: 272 seconds]
m6w6_ is now known as m6w6
kenran has joined #zig
craigo has quit [*.net *.split]
marler8997 has quit [*.net *.split]
casaca has quit [*.net *.split]
ed_t has quit [*.net *.split]
tughi has quit [*.net *.split]
racoon has quit [*.net *.split]
knebulae has quit [*.net *.split]
nickster has quit [*.net *.split]
isolier has quit [*.net *.split]
nickster2 is now known as nickster
isolier2 is now known as isolier
craigo has joined #zig
ed_t has joined #zig
casaca has joined #zig
tughi has joined #zig
knebulae has joined #zig
07IAAT3BB has joined #zig
ed_t has quit [Excess Flood]
07IAAT3BB has quit [Max SendQ exceeded]
ed_t has joined #zig
craigo has quit [Ping timeout: 254 seconds]
tughi has quit [Ping timeout: 254 seconds]
knebulae has quit [Ping timeout: 254 seconds]
a_chou has joined #zig
Snektron has quit [Ping timeout: 244 seconds]
vazub[m] has quit [Ping timeout: 244 seconds]
kameliya[m] has quit [Ping timeout: 244 seconds]
pafmaf[m] has quit [Ping timeout: 244 seconds]
vazub[m] has joined #zig
kameliya[m] has joined #zig
pafmaf[m] has joined #zig
skuzzymiglet has quit [Quit: WeeChat 3.0.1]
skuzzymiglet has joined #zig
Snektron has joined #zig
st4ll1 has joined #zig
mokafolio has quit [Quit: Bye Bye!]
knebulae has joined #zig
watzon has joined #zig
watzon has quit [Quit: authenticating]
watzon has joined #zig
jokoon has quit [Quit: Leaving]
plumm has joined #zig
sord937 has quit [Quit: sord937]
a_chou has quit [Quit: a_chou]
a_chou has joined #zig
* plumm does a backflip
Techcable has joined #zig
midgard has quit [Ping timeout: 264 seconds]
zags has joined #zig
remby has joined #zig
xackus has joined #zig
midgard has joined #zig
xackus_ has quit [Ping timeout: 240 seconds]
xackus_ has joined #zig
xackus has quit [Ping timeout: 264 seconds]
ave_ has quit [Quit: Ping timeout (120 seconds)]
ave_ has joined #zig
lunamn has quit [Quit: Ping timeout (120 seconds)]
lunamn has joined #zig
cCCCCcccccCCc has quit [Ping timeout: 260 seconds]
kandinski has quit [Ping timeout: 260 seconds]
jjsullivan has quit [Ping timeout: 260 seconds]
jjsullivan has joined #zig
ed_t has quit [*.net *.split]
sjums has quit [*.net *.split]
haliucinas has quit [*.net *.split]
xentec has quit [*.net *.split]
Nilium has quit [*.net *.split]
cow-orker has quit [*.net *.split]
andrewrk has quit [*.net *.split]
lonjil has quit [*.net *.split]
losinggeneration has quit [*.net *.split]
crimson_penguin has quit [*.net *.split]
Ankhers has quit [*.net *.split]
plumm has quit [Quit: Textual IRC Client: www.textualapp.com]
crimson_penguin has joined #zig
sjums has joined #zig
xentec has joined #zig
ed_t has joined #zig
haliucinas has joined #zig
Nilium has joined #zig
cow-orker has joined #zig
losinggeneration has joined #zig
andrewrk has joined #zig
lonjil has joined #zig
Ankhers has joined #zig
lonjil has quit [Max SendQ exceeded]
lonjil has joined #zig
skuzzymiglet has quit [Ping timeout: 264 seconds]
remby has quit [Quit: remby]
skuzzymiglet has joined #zig
kenran has quit [Quit: leaving]
remby has joined #zig
Swahili has quit [Remote host closed the connection]
<leroycep> v0idify: could you use `readUntilDelimiterOrEofAlloc`?
hnOsmium0001 has joined #zig
blackpawn has quit [Ping timeout: 260 seconds]
Techcable has quit [Remote host closed the connection]
xackus has joined #zig
xackus__ has joined #zig
zags has quit [Read error: Connection reset by peer]
zags_ has joined #zig
xackus_ has quit [Ping timeout: 265 seconds]
xackus has quit [Ping timeout: 240 seconds]
mokafolio has joined #zig
<andrewrk> wow, brilliant, vexu already has all the translate-c tests passing in ast-memory-layout branch
<ifreund> very nice :)
leroycep is now known as geemili
<ifreund> andrewrk: I'm working on the trailing doc comment fixup by the way (though half of me thinks they should be a compile error, I saw you added explict support in the parser)
<andrewrk> by trailing, you mean same-line ones?
<ifreund> yeah
xackus has joined #zig
<ifreund> they zig fmt tests want to move them before the decls
<andrewrk> hmmm. making them a parse error sounds like a reasonable proposal
<andrewrk> allowing them prompts a few questions, such as, how should generated docs represent it when there are doc comments before as well as same line
<andrewrk> it might be really nice to do same-line doc comments for parameters though
<ifreund> I don't think we support them for parameters
blackpawn has joined #zig
<ifreund> only for var decls and struct fields
<ifreund> search for parseAppendedDocComment() in parse.zig
xackus__ has quit [Ping timeout: 240 seconds]
<andrewrk> ah I see
<ifreund> or nevermind, we don't support them on struct fields yet post-rework
<ifreund> we do support them after extern function decls though :D
<ifreund> I'd be happy to remove all support, though I don't want to make functional changes from master without the go-ahead from you
zags_ has quit [Quit: leaving]
mikdusan has quit [Quit: WeeChat 3.0.1]
<andrewrk> go ahead and make same-line doc comments parse errors
<ifreund> :)
n0tekky has joined #zig
Techcable has joined #zig
<noam> ifreund, andrewrk: are same-line non-doc comments okay? Or should those error too?
<noam> I feel like for consistency prohibiting both on the same line makes sense
<noam> It also removes abiguity...
<ikskuh> what ambiguity?
<ifreund> noam: I see no reason to disallow those
<ifreund> they are very useful
<noam> Ah, hm. I take that back; ambiguity is only a problem for doc comments
Swahili has joined #zig
fritchie has joined #zig
<ifreund> zig fmt is getting pretty close. Main things left are proper handling of comma separated lists (e.g. wrapping and inserting a trailing comma if line comments are present) and the newish feature allowing columns in list literals
<ifreund> other than those two features I think it's just bugfixes for what we already have implemented
<ifreund> off to bed now though
remby has quit [Remote host closed the connection]
emptee has joined #zig
<andrewrk> good night!
Akuli has quit [Quit: Leaving]
<v0idify> i love how this channel is a mix of "user-land" stuff and compiler stuff
craigo_ has quit [Ping timeout: 240 seconds]
xackus_ has joined #zig
zags has joined #zig
xackus has quit [Ping timeout: 265 seconds]
Snaffu has quit [Ping timeout: 272 seconds]
roykalony has joined #zig
roykalony has quit [Client Quit]
a_chou has quit [Quit: a_chou]
mikdusan has joined #zig
donniewest has quit [Quit: WeeChat 3.0.1]
mikdusan1 has joined #zig
mikdusan has quit [Ping timeout: 264 seconds]
mikdusan1 has quit [Ping timeout: 240 seconds]
mikdusan1 has joined #zig
<v0idify> how can i compile stage2 with <6GB RAM?
<andrewrk> v0idify, that's something we're working towards, but not capable of yet
<andrewrk> we're using lots of ram as a crutch to get the language done faster
<v0idify> andrewrk, does building stage2 with stage2 take less RAM?
<andrewrk> rest assured there are significant efforts underway towards better resource utilization
<v0idify> \o/
<andrewrk> stage2 can't build stage2 yet, but, yes it is significantly improved both in terms of perf and ram
<v0idify> :D
<mikdusan1> zig -target mos6502-appledos-freestanding, when? :P
emptee has quit [Quit: Konversation terminated!]
<mikdusan1> oh that would be `-target mos6502-freestanding`
n0tekky has quit [Quit: Leaving]