ChanServ changed the topic of #zig to: zig programming language | ziglang.org | be excellent to each other | channel logs: https://irclog.whitequark.org/zig/
daurnimator has quit [Ping timeout: 240 seconds]
daurnimator has joined #zig
moo has joined #zig
wootehfoot has quit [Ping timeout: 250 seconds]
metabulation has joined #zig
moo has quit [Ping timeout: 268 seconds]
ibebrett has joined #zig
metabulation has quit [Read error: Connection reset by peer]
steveno has quit [Ping timeout: 260 seconds]
nodist has joined #zig
mpiannucci has joined #zig
<mpiannucci> Hey has anyone managed to cross compile for iOS? I have been working through by trying to fix compiler issues as I go, but wanted to see if anyone else has any tips or has attempted it.
<scientes> just like that Duch...gone
nodist has quit [Quit: Leaving]
<ibebrett> can anyone give me some insight on whats wrong with:
<ibebrett> fn formatDigit(byte: u8) u8 { return switch(byte) { u8(0) => '0', else => 'x' }; }
<ibebrett> i keep getting: error: unable to infer expression type
<ibebrett> This does compile: fn formatDigit(byte: u8) u8 { return switch(byte) { else => 'x' }; }
benjikun has joined #zig
steveno has joined #zig
mpiannucci has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
_whitelogger has joined #zig
steveno_ has joined #zig
steveno has quit [Ping timeout: 268 seconds]
steveno_ has quit [Ping timeout: 272 seconds]
suirad has quit [Ping timeout: 256 seconds]
<ibebrett> is there an issue using the c allocator within a test
<ibebrett> i think it was just that i didn't add the c library as a dependency for the test step, the error message was something about there being two _start symbols though
<ibebrett> is it possible that linking c changes the zig compilers entry point?
<scientes> ibebrett, yes, if you link with libc you need a int main
<scientes> but otherwise zig provides a _start
<ibebrett> so i think the "test" step
<scientes> (at x80 on x86)
<ibebrett> maybe it could be a nicer error message
<ibebrett> for linking the builder "test" stuff
<ibebrett> instead of ilke "undefined symbole malloc"
<ibebrett> i got two _starts
<scientes> yeah you should report that as bug
<scientes> tests generally use the test allocator
<ibebrett> ah
<scientes> but tests really should support libc linking too
<ibebrett> that also, would have been good to know lol
<ibebrett> but yeah, ill report it anyway
<scientes> yeah you have to read code to get documentation of stuff not part of the language
<scientes> actually tests _are_ part of the language....but still kinda undefined
<scientes> *undocumented
<scientes> see https://github.com/ziglang/zig/issues/480 for discussions about allocators
<scientes> yeah you want the debug allocator
<scientes> which is just a static single allocation of memory
<scientes> very simple
<scientes> Oh, so it works if you link to libc?
<ibebrett> yeah
<scientes> oh
ibebrett has quit [Ping timeout: 256 seconds]
basro has quit [Disconnected by services]
basro_ has joined #zig
basro_ is now known as basro
suirad has joined #zig
reductum has quit [Quit: WeeChat 2.3]
Zaab1t has joined #zig
benjikun has quit [Ping timeout: 246 seconds]
benjikun has joined #zig
wootehfoot has joined #zig
qazo has quit [Read error: Connection reset by peer]
qazo has joined #zig
robbym has quit [Ping timeout: 272 seconds]
Zaab1t has quit [Quit: bye bye friends]
benjikun has quit [Ping timeout: 250 seconds]
noonien has quit [Quit: Connection closed for inactivity]
wootehfoot has quit [Read error: Connection reset by peer]
mpiannucci has joined #zig
mpiannucci has quit [Client Quit]
very-mediocre has joined #zig
ibebrett has joined #zig
daurnimator has quit [Ping timeout: 252 seconds]
daurnimator has joined #zig
mpiannucci has joined #zig
mpiannucci has quit [Client Quit]
<ibebrett> got an error: ../zig/build/bin/zig build test zig: /home/brett/w/zig/src/ir.cpp:18694: IrInstruction* ir_analyze_instruction_slice(IrAnalyze*, IrInstructionSlice*): Assertion `ptr_type->id == ZigTypeIdPointer' failed. The following command terminated unexpectedly:
<ibebrett> this to me seems like a bug?
hio has joined #zig
daurnimator has quit [Ping timeout: 252 seconds]
daurnimator has joined #zig
ibebrett has quit [Ping timeout: 256 seconds]
Yaargh has joined #zig
very-mediocre has quit [Ping timeout: 256 seconds]
reductum has joined #zig
unique_id has joined #zig
<unique_id> ibebrett: Yep, that's a bug. As I understand it, not all of these kinds of bugs will be fixed in the current compiler. Rare edge cases that don't matter will be fixed in the self hosted compiler (written in Zig). The current compiler will later be used just to compile the self hosted one. You can file a bug report and it'll either get fixed or at minimum be used as a test case for the self hosted compiler.
<unique_id> I used to come across a fair bit of these assertions, now I don't.
<unique_id> Of course if it's code that should compiler, that's a different story
<unique_id> compile*
Zaab1t has joined #zig
steveno_ has joined #zig
vegecode has quit [Ping timeout: 268 seconds]
Zaab1t has quit [Quit: bye bye friends]
basro has quit [Disconnected by services]
basro has joined #zig
basro has quit [Disconnected by services]
basro_ has joined #zig
basro_ is now known as basro
steveno_ has quit [Remote host closed the connection]
Yaargh has quit [Quit: Going offline, see ya! (www.adiirc.com)]
unique_id has quit [Ping timeout: 272 seconds]
daurnimator has quit [Ping timeout: 252 seconds]
mpiannucci has joined #zig
daurnimator has joined #zig
qazo has quit [Ping timeout: 250 seconds]
mpiannucci has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
reductum has quit [Quit: WeeChat 2.3]