🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). Log available at irclogs.raku.org/raku/live.html . If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 6 September 2022.
00:01 reportable6 left 00:02 sena_kun left, lichtkind left 00:04 reportable6 joined 00:53 jaguart left 01:13 jaguart joined 01:29 deoac left 01:30 squashable6 left 01:31 squashable6 joined 01:38 razetime joined
ToddAndMargo native call question:  how do I declare a pointer to a pointer (*ppSession)? 01:53
my $ppSession  = NativeCall::Types::Pointer[NativeCall::Types::Pointer].new();
give me a bogus value 01:54
Is there a way to do this with NativeCast? 02:37
02:38 evalable6 left, linkable6 left 02:39 evalable6 joined, linkable6 joined 02:42 Kaiepi left 03:42 evalable6 left, linkable6 left 03:43 falsifian joined, linkable6 joined, evalable6 joined 04:25 Kaiepi joined 05:17 Sauvin left 05:18 Sauvin joined 06:00 reportable6 left 06:01 reportable6 joined
Kaiepi .tell jjmerelo is there time for a short-ish draft or two for advent? 06:16
tellable6 Kaiepi, I'll pass your message to jmerelo
Kaiepi uh
oh that is his nick 06:17
06:32 derpydoo left 06:50 razetime left 07:16 razetime joined 08:03 razetime left 09:03 coverable6 left, bloatable6 left, committable6 left, statisfiable6_ left, benchable6_ left, unicodable6 left, quotable6 left, releasable6 left, evalable6 left, reportable6 left, tellable6 left, squashable6 left, notable6 left, shareable6_ left, bisectable6_ left, greppable6 left, linkable6 left, shareable6 joined 09:04 unicodable6 joined, tellable6 joined, linkable6 joined, releasable6 joined 09:05 squashable6 joined, bisectable6 joined, reportable6 joined, greppable6 joined, evalable6 joined 09:06 quotable6 joined, coverable6 joined, benchable6 joined, committable6 joined, statisfiable6 joined, notable6 joined, bloatable6 joined 09:24 ProperNoun left 10:24 statisfiable6 left, unicodable6 left, linkable6 left, shareable6 left, nativecallable6 left, tellable6 left, sourceable6 left, evalable6 left, squashable6 left, coverable6 left, greppable6 left, reportable6 left, benchable6 left, bisectable6 left, releasable6 left 10:25 squashable6 joined, tellable6 joined, greppable6 joined, statisfiable6 joined, reportable6 joined, linkable6 joined, bisectable6 joined 10:26 shareable6 joined, sourceable6 joined, unicodable6 joined 10:27 nativecallable6 joined, coverable6 joined, releasable6 joined, evalable6 joined, benchable6 joined 10:46 lichtkind joined
sarna docs.raku.org/routine/spurt says that "spurting a Blob when the handle is NOT in binary mode is undefined" - what if I spurt a Blob to `$*OUT`? as per `IO::Special` docs, its `.mode` will always return Nil 10:51
am I missing something?
10:51 Sgeo left
sarna it seems to work fine, but in docs there are also examples of subs called on `$*IN` where "Attempting to call this method when the handle is in binary mode will result in X::IO::BinaryMode exception being thrown." 10:58
so I think it can't be in binary mode, right? am I invoking UB? 10:59
Nemokosch that wouldn't make a whole lot of sense, to be honest; because by the same reasoning, spurting textual content to $*OUT would also be UB 11:02
which is nonsense
sarna why would that be? spurting a Cool is okay iff the handle is not in binary mode (as per docs) 11:04
Nemokosch ż as per IO::Special docs, its .mode will always return Nil
sarna ah, that. yeah.. I'm confused 11:05
Nemokosch I'm leaning towards the documentation is wrong. But what is right then, I don't know.
sarna for now I'll do `temp $*OUT = open '/dev/stdout', :w, :bin` 11:06
ahh, `.mode` refers to the permissions, not binary or not binary. like `0644`. now it makes sense why it's Nil for `$*OUT` 11:09
but now.. if I have a filehandle, can I tell if `:bin` was passed when it was created? there's no `.bin` method
11:13 sena_kun joined
sarna ahh, it needs to be an `IO::Handle` and not `IO::Path`. `.encoding` needs to return Nil. this is hard >:( 11:15
Nemokosch I can't follow you for sure xD 11:16
sarna yea sorry. in short, this works for ensuring the handle you get is in binary mode (so it's safe to spurt a Blob there): `$handle.encoding === Nil` 11:20
Nemokosch it's strange that there is no interface for this... 11:21
sarna if you find one, let me know :) 11:22
Nemokosch okay 😄
11:25 Nemokosch joined
Nemokosch .seen japhb 11:25
tellable6 Nemokosch, I saw japhb 2022-11-24T18:28:52Z in #raku-dev: <japhb> Yeah, that's my guess, forced pushes
Nemokosch I wouldn't want to open an issue for this because I'm not sure if this is a legit thing to do in the first place...
.tell japhb in Terminal::LineEditor, if you do something like $*IN.lines, you get a prompt that you can finish with ctrl+d, however, it's not possible to get input for the console anymore afterwards, and it needs to be killed. Is this something intrinsic for how the REPL works or can it be fixed? 11:27
tellable6 Nemokosch, I'll pass your message to japhb
11:28 Nemokosch left 11:31 andinus`` is now known as andinus 12:00 reportable6 left 12:01 reportable6 joined 12:08 lichtkind_ joined 12:10 lichtkind left 12:11 razetime joined 12:23 Kaiepi left 13:03 Kaiepi joined 14:03 linkable6 left, unicodable6 left, sourceable6 left, benchable6 left, coverable6 left, committable6 left, tellable6 left, shareable6 left, notable6 left, quotable6 left, squashable6 left, nativecallable6 left, greppable6 left, evalable6 left, bloatable6 left, statisfiable6 left, reportable6 left 14:04 sourceable6 joined, notable6 joined 14:05 evalable6 joined, linkable6 joined, greppable6 joined, quotable6 joined 14:06 coverable6 joined, benchable6 joined, statisfiable6 joined, committable6 joined, shareable6 joined, nativecallable6 joined, reportable6 joined, unicodable6 joined, tellable6 joined, squashable6 joined 14:07 bloatable6 joined 14:13 Guest4174 joined 14:50 holyghost joined 14:51 holyghost left 14:52 holyghost joined 14:53 holyghost left 15:17 Voldenet left 16:03 sena_kun left 16:05 sena_kun joined 16:23 Xliff joined, Xliff left, Xliff joined 16:37 jonasjlinde joined 16:47 Voldenet joined
ToddAndMargo NativeCall pointer questions: I got it working. 17:05
17:05 ToddAndMargo left 17:10 jonasjlinde left 17:33 razetime left 18:00 reportable6 left 18:01 Sgeo joined, reportable6 joined 18:11 sena_kun left 18:17 sena_kun joined 19:17 linkable6 left, evalable6 left 19:18 evalable6 joined 19:19 n1to joined 19:20 linkable6 joined 19:30 sena_kun left 19:31 sena_kun joined 19:34 Kaipei joined 19:38 Kaiepi left 19:44 ProperNoun joined 19:45 n1to left 19:55 ProperNoun left 19:57 ProperNoun joined 19:58 epony left 20:38 Bocaneri joined, Bocaneri is now known as Guest3282 20:39 MoC joined, Sauvin left, Guest3282 is now known as Sauvin 21:00 smol-hors joined
smol-hors henlo 21:00
Nemokosch suppers 21:02
Voldenet ehlo 21:38
21:47 Guest4174 left 22:36 Kaipei left 22:47 jgaz joined 23:16 jgaz left 23:23 sena_kun left