#programming
1 messages · Page 96 of 1
Meaning valid JS is valid TS. But not all valid TS is valid JS
You don't need that flag anymore
You do in the article you send though
But do namespaces and enums and stuff work too now?
From 23, it does not I think
Still only stripping type from what I understand
Yeah, for that to work you still need flags
Just figured out how to compensate for Bluetooth audio latency while watching videos/streams 
But casually how can I build an ai like neuro though
learn
neuroDinkDonk bingo alert

@opaque sigil ok so I'm getting fed up with hyper-v networking and using nixos-wsl instead om
why not just dual boot
dual booting is annoying
I cannot setup a dual boot from a different country without a lot of prayers and even then idk I just dislike dual boots
and I don't wanna dual boot on my laptop
I could be tempted by a cheap ThinkPad for Linux though
so are vms
thats how i initially tried nixos to be fair
a vm doesn't make me reboot every time i want to use the other system 

is there a single sentence with coherent structure, that can hit a #programming bingo in one go
no
already some conflicts, like super rare vedal appearance coinciding with new chatter
also the one that is 5+ people required
cant be done in one sentence
middle horizontal one feels doable
"conversation starter"
if i have to do a modcheck here i'll just tell ya'll to mark your bingos sheets 
i think these ones could all be done in a single sentence
but it would have to be from an ai spambot that just joined the server
that has inexplicable knowledge about #programming lore

actually i missed one, #programming inside joke gets art should also work
also this person needs to get promoted to moderator before they send their message
so modcheck in theory could also work
i think sending this message would get you instantly banned though
the art one is never happening ever again after december
don't include spambots
... mainly cos ya'll summon us
but also cos the spambots aren't on topic
ultra rare vedal appearance.. yeah no, not for another 2-3 months in #programming 
what's the definition for doomposting though
how do you doompost from only one sentence
well a modcheck is a modcheck 
thats a bingo square
also me being here rn is a bingo square 
quick, ask a question about neuro
ahh problem
we need more squares

i just realised that this person would have to be a twitch subscriber otherwise they wouldnt be able to embed images
Oh true
either that or a moderator 
if a mod is compromised there's bigger problems than the scams
aka someone already got scammed
vedal appearing could cause three bingos if he wanted to
The way Magistral breaks down its chain of thought into reasoning steps is really interesting
None of the other open weight reasoning models do this
That I know of anyway
How many bottle of banana rum would be need to bribe vedal to help us 🤔
It has the full reasoning trace broken up into steps dedicated to specific lines of inquiry like the ones you might see on a consumer frontends summarised version
i think it would be impossible 
NaN Bottles then.
Got it. So make the ai bot also somehow summon vedal to appear
vedal amnesia bingo
then he can be a new chatter too
doesnt add any new bingos but does add another square
a ping could do 
with some kind of multiple personality disorder perhaps we could also get os/editor wars and poll from 3 people
Nah, you'd just turn instantly to dust
are there any AI bots in history pinged vedal
It needs to be something that vedal actually needs to intervene / clarify

guys why is my ssh struggling on a 6500kbps link speed wifi connection
package loss?
I think I just have a terrible connection to the router
If the other side is on dial up, I think it will cause problem too
bro get ethernet
like
its an lte modem
it's a wire
:3
oh
it has no holes aside from usb
evil eats a lemon and dies

🍋 
true
imagine someone in the future wants to ping vedal, but pinged the vedal987 account instead
which is owned by me 


Hmm, very wise
millipede
millipede
Friend came by to play more res evil 4, we're stuck on the boss of disc 1 
I have centipede issue here at my place
They kept crawling from somewhere into my bedroom
Also i tried kindom hearts for ps2, but tbh it kinda sucks ngl
the russian word is straight up many- right, and forty- for centipede
why lie fym 100 and 1000
apparently they are all just called many-
forty- is just the archaic name
oh? i always thought they referred to millipedes and centipedes respectively
ok maybe not archaic but either way the reason its 40 is because 40 used to also mean "many" for random christian reasons (edit: may alternatively be related to fur trade)
mhm
m
tl;dr I have elected that my previous idea is
clearly the best idea for how to proxy moonlight
but I want it in an appimage
so like

time to build an appimage
which surely is best done from a nix flake
reasonable assumption tbf
though wouldn’t it be faster to just throw it together if you need it only for yourself
its probably stupid
but I don't want to make my ubuntu wsl install any worse with random appimage building stuff
and I really should learn nix at some point
moments where AI is actually useful to me: my router likes to invalidate my private ip if im not making any net requests so i made AI create a program that constantly pings 1.1.1.1 (i couldnt be bothered to work with windows api myself)
pretty neat, i also have it on my startup apps too
also -- please do not ask me why my router does this I HAVE BEEN LOOKING INTO THIS ISSUE FOR 5 MONTHS AND FOUND NOTHING!!!! why must my router do me like this 
you dont have to work with winapi you could've just ping -w 1.1.1.1
(or whatever the windows flag for infinite ping is)
id rather not open a command prompt window each time i start my pc
you can autostart it
yeah but the window is never hidden too
if it's the private IP why not just set a static one? does your router not allow setting the address range for the DHCP server?
that was my original solution too, it just got annoying
ive tried that too, DHCP ignores the lease time and just invalidates it, and boots me off my wifi
i even set the lease to 1 month and 2 days later i get kicked off
not that I've noticed, no
im not sure if its a driver problem
Huh, this is news for me then
wait it probably is a driver problem for windows, i switched to linux for a short time and my wifi always worked on it
but when its windows it never works
one of the things i saw while troubleshooting is that my wifi network is duplicated 2 times, same signal strength but the wifi name of the duplicate is empty, but im not sure if thats causing it
if you set a static IP on your device then whatever the routers DHCP server does shouldn't matter
that's the whole point of having a range for statically assigned IPs
im talking about in general, ive set lease time for my device, and tried setting a static ip, none worked
sorry if i was vague when i sent that message
its been happing for a good amount of time
its only windows that does it too
yeah, more likely an issue with your device than with your router then
i have to switch the channel whenever i try connecting, I have a repeater thats upstairs, i connect to it, then go to my panel and then switch the channel to be either channel 1 or 6, save it and then pray that when i connect to the main one it actually works and then start pinging 1.1.1.1
microsoft moment
its so weird
this is the ONLY fix that ive found within the 5 months of it not working, and it resets whenever i restart my pc
exactly
im not too sure how i found it
i was just messing with alot of stuff
i think this was after i was messing with DHCP
hm a thinkpad is so mildly tempting
im genuinely thinking of moving over to linux though, my only gripe is that anything above 120hz does not work and results in a black screen when moving my cursor or using my keyboard
probably a driver issue but i cba to look into it right now
oh and also the fact most of my apps are windows only 
that definitely sounds like a driver issue or sth, my 240hz monitor works just fine
i feel like i'm getting more sponsorship spam lately
Are you a content creator chay?
i technically was many years ago
"many years ago" is how i know they just send these emails indiscriminately
What's wrong with Nvidia GPUs? I have two different Nvidia GPUs in my Linux system and it works flawlessly
it's gotten better recently
they've been really unreliable for me, especially in linux
but historically nvidia has been very uncooperative
Those recent upgrades must have really made a big difference, I have encountered 0 GPU related issues
Not any that weren't user error anyway
It's still a bit more effort to set up but after that it should just work, thankfully there's a driver for using vaapi via nvdec now 
For me it was just a matter of installing the driver
And that was made very easy by Mint coming with a driver manager thingy
Yeah mint will do this for you automatically
i am here
Hi here 
hello 
reading about flakes is fun 
honestly most of the "weirdness" comes from the fact you now have to do all the initial plumbing yourself rather than relying on the nixpkgs module system from the start
No guide about flakes quite explains it well, some people might default to how you first use it; some might look at packages that have upstream nix code. It's a very nice system that is expanded by just allowing a version of nixpkgs.
There is always the example of two sets of nixpkgs, but I'm personally for the extra apps and options that other projects can add ontop of the defaults.
https://www.youtube.com/shorts/S3j1MMoVunw
i like this yt channel
hi
I wonder how many viewers can Twitch handle wasn't it so 1.2 mio with this Spanish streamer ?
the current record is 3.8M
on firefox is there a way to ozom in on websites other than ctrl + and settign the zoom function on the settings? For some reaosn this one website im using doesnt zoom in with any of these options. tried an extension zoom we too
Try CTRL + scroll?
same thing doesnt do anything
The site has probably captured input then
i think its because this monitor is 4k
doesnt look too bad on my other one so guess ill have to just swap em over
yh its based off display resolution only rip
nvm figured it out o7
you could set the monitor to 150% zoom thats what i have mine set to
My PC really enjoys the experience of running reasoning models
hell yeah
Morning
today i learnt that training an AI model on a tablet is a terrible idea

Lol how did you even get to that point
a snapdragon gen 3 pro max ultra whatevert he fuck, or a 3090?
who would win? 
hmmm tough choice you know 
attempt 2
it is only a bad idea if my tablet explodes (it turned off because tmax)
it did WHAT?
aww gdi
Making any modern computing device turned off from overheat is a feat on its own tbh
it cant be that bad, ive only been at 100% cpu usage for the past hour
raaaa it froze again
maybe you should put it in the fridge or so to train
wtf it killed my browser
remind me again why you're doing this?
The tablet upon seeing vanor entering the room: 
what cpu does it have?
Some people likes pain. Maybe vanor is one of them
we knew that already
like an i5-1235U i think
that poor thing
oh so x86?
is it capping cpu or gpu?
tmax is just a number
its also the boiling point of water
caps cpu, this thing has an igpu
does the igpu count towards cpu usage? it shouldnt?
i think loading data into ram requires the cpu, but i might be wrong
the igpu still reads from the ram
anyways it probably doesn't help im trying to compile something at the same time
maybe i should consider doing less
damn that thing has 10 cores and 12 threads. for a tablet thats unexpected
8e 2p
checks out
ya that

ig this doesnt make sense without the labeling 
here they are 
this is so cursed
i love openvino
man my head hurts
why does ssh 5090 is not using huggingface datasets
while my 3070 dies of OOM but still manages to do that
🤔
i should check components again
remember the 5090 has a hard requirement on cuda 12.8+
could also be some locked down network
(idk where you got the 5090 from)
Vanor be out there, stress testing computing device
do yall rate your files tho?
Never; I forgot that was a thing 
only really makes sense for songs, imo
Huh. KDE Dolphin has it too
at least it's not an option on every file type—I can't rate my text files, and I'm not sure whether to be disappointed or not
As we are all autistic femboys and catgirl here we are great at programming we should make a program that hypnotizes politicians into becoming femboys and catgirls.
wtf??
no comment xd
i just remembered my interviewer asked me how much ram i had
that was pretty cool
Are you alright? Are you drunk?

hey pssttt.. by the way, how much ram you got? cuz our project folders are unoptemized as fuck and you're gonna need at least 64GB
a lot of people use it for photographs they took
Imma be honest Sam, it doesn't even look cooked
its just maintaining its shape well
Suuure 
the water is hot so it is cooked
you just have high noodle standarts as an asian person
I was removed from existence for a while, but it sure isn't locked network
i should try a different method
Well, I think even Indomie recommends to cook the noodle in boiling water for at least 3-5 minutes 
i did
that is... wow, really something
I just eat oatmeal in the mornings
Its fine
...
I really don't understand where would the flavour even come from based on the original looks
did you just put only the boiled water or something
The litle pack of powder
you did add it??
Yes
Now I want some noodles
I like more spicy noodles myself. The broth will turn red and even then, I still like to add more powdered chili
the humble buldak sauce 
Yep
We grilling Sam again? LFG
I mean the water literally looks like it changed color only due to the noodles
I still refuse to believe that powder stock package still results that color after adding it to that small amount of water
It was fine
Yall are so pedantoc about noodles
you're supposed to use that litle water,t he pack said 300ml
thanks for this picture
seems like we were too biased towards korean ones where broth is red/orange
update on my datasets:
even the huggingface datasets logging is not showing anything

it was blazingly fast for pip fetch
but why huggingface fails
Granted I don't use a dedicated water boiler, but I usually go the least amount of water needed to have all of the noodles submerged.
no need to be wasteful
(It's also more fun because you place in too little and quickly got to refill it)
I like to drink the broth after eating the noodles tho. So no waste there
I see thin-film interference 
i think its mostly just the reflection of my monitor
this cannot be real
my credentials were not used at all
but there was no bug raised
wtf
I procrastinated a bit to much today so I won’t be able to work on the art program, I think the next feature I’ll add is the ability to rearrange layers, then duplicating layers. Mainly because I want to add frames and make animations.
Also I should probably change the version number that I’m calling it now that undo-redo is here.
I realized earlier that the cursed undo solution that unconputable thought of wasn’t actually that bad as it would basically be an layer of just a single action rather than including all the past actions in each new layer. Which I technically have to make anyway if I want to preview the current action. Just without storing the action layer that is.
Yeah, it will just require you to store an insane amount of layer internally
Still cursed tho
The small benefit is you could crop the images, but yes. also I don’t think I could preview the fill bucket unless the preview layer has the whole image.
i like how ruff always offers #ignore <the giant problem that will cause program to not function> as a fix
True
If you were to draw a horizontal line, after how many pixels would image.fill_rect() be better than image.set_pixelv()
Profile it and find out 
I have to sleep first, and I don’t want to write purposeless code in this project so I’ll have to make a new project for testing this.
I’m wandering because I think my fill bucket uses set_pixelv() and I think converting it into rectangular chunks and using fill_rect() would probably be faster, but that’s a lot of unnecessary work if drawing it isn’t a big issue at all compared to searching the image for the pixels to fill.
it probably all depends on what you're using, but the only real answer is profile it
why did i see sad instant noodles the moment i open the channel
you guys should invest in coffee ramen, it gives you all the nutrition you need to tackle the day
What even is that?
Noodles with coffee as the broth?
yes (it does not taste good)
is it a good idea to convert my spare surface into a mini-server
is it a laptop surface or a tablet surface
i know the tablet ones overheats a lot, like the current one im using
tablet one does overheat but that's not much more of an issue if you leave it in a cool environment directly in front of a fan right 
ya bro i personally like to put my tablet in the arctic whenever i feel like opening 2 chrome tabs
I prefer this then
I think if the surface is just idling then why not
mi goren my beloved
Vanor no.
For anybody wondering, this is what it looked like when he made the Coffee Ramen
He also made Protein Powder Ramen before
Why 
I dont know

Are y'all secretly ID or got some hidden route to Indomie mi goreng?
its sold everywhere in australia
Ahh, our so close yet so far neighbor

uacslop
a reminder for what admin protection is about #programming message
no it probably tastes mid
my tummy hurts just looking at that
water 
Microsoft finally getting sudo
(it's off cause i use gsudo)
Well, technically it isn't sudo either. Is it PAM or DBus that ask for authentication when some GUI app want to access some privileged action?
pam
I'm gonna crash out when the web-sys crate makes me add another feature
Indeed there is
hmm I wonder if there're vulnerabilities of forcing admin privileges or bypassing this prompt 
none yet this is pretty new
traditional UAC bypass methods won't work because you can't just pass around tokens like that anymore with this on
soon™
windows is a big chunk of tech debt
meh
this model is a lot more secure and resilient than previous implementations since it relies on an entirely new account and SID/SMAA
since it relies on a new shadow account the SID is different

Now the question is, will they deprecate the old stuff and introduce backward incompatibility or not
probably redirecting the apis ngl
knowing microsoft they will just support both until the end of time
more tech debts 
it is an entirely optional feature
privileged shadow account can't access processes on the standard account now
Because the actual problem is that. MS is accumulating a lot of tech debt from maintaining backward compatibility so far back to the past
hell
heaven
Earth
Mars...? 
OGLE-2005-BLG-390Lb
konii be out here giving out cryptic messages from Mars
Oh wait no, that's distant earth like planet
I raise you all, the observable universe
Thats not a planet
But for all we know, the universe could be a hologram on the surface of a black hole
So still 1 spherical celestial object
Holograms?
Yes, because for some odd bizzare reasons, the information required to describe the smallest unit of space is not a voxel, but reducible to a hologram on the surface of a sphere
Do you know what a hologram is?
I thought the smallest unit of space was described in energy
Ngl im thinking about hatsune miku here
Well, that is holographic display or projection that you're imagining. What I mean is hologram in the sense that you can capture 3D scene on a 2D plate
See this video
https://www.youtube.com/watch?v=EmKQsSDlaa4
3d scenes on 2d film, and a diffraction lesson along the way.
Instead of sponsored ad reads, these lessons are funded directly by viewers: https://3b1b.co/support
An equally valuable form of support is to share the videos.
Hologram credits:
The Microscope is by Walter Spierings, 1984
Donations Hologram by Cherry Optical Holography
Lucy in a Tin...
It provides a good basis of understand light hologram
I did see that one before ye
If light, i.e. electromagnetic waves can be captured on a surface of 2D plate, then so does every other wave can be described on the same way
Yes
So a hologram on the surface of a black hole can, in theory, encode a whole universe
Or at least object that falls into it
neither tsocks nor proxychains (nor proxychains-ng) seem to support udp
That makes sense but that doesnt mean the universe isin one
Ngl, I never understood your problem in the first place. Can you maybe draw out some diagram to helps us understand it better?
That's the thing. We cannot know
Or at least, not that we know of currently
My vote is on us not being inside a black hole
The many world interpretation could just be multiple black hole lol
sure, gimme like 5m lol
For the universe to be a black hole wed need a dense mass at the center and im pretty sure we wouldnt be able to see light from all directions due to it being sucked in
We do not know what lies beyond the event horizon. We just know that the model state there is a great disturbance of space-time at the center of one. Also, any interaction inside the black hole technically is no different from the outside. Just that space and time got flipped. There are too many unknown tbh to state with certainty
Besides, the encoding happen at the surface
not the best diagram, but basically trying to replicate the experience on my laptop; instead on any (linux, or specifically ubuntu) machine that I don't have root on
Ouch, yeah, not having root is quite an issue there. I need to check tailscaled docs one sec
my current ideas are:
- try and make
tsocks,proxychains,proxychains-ngwork - recompile
moonlight-qtso it doesn't explicitly disallow proxies - make a proxy myself that can forward packets to tailscaled whilst also acting as a sunshine host (this might also be possible with
sshtunnels instead of making my own proxy if I can force ssh through a socks5 proxy)
it can make a socks5 proxy in userspace-networking mode iirc
(also advanced warning, my messages might take ages to send so sorry if I say something at a stupid time 😭)
https://mystb.in/52f57b502eb74a48ac has the output of tailscaled --help
also worth noting that despite the obvious drawbacks of tcp, I'm not too worried because I'm probably only going to be streaming at a low bitrate anyways
Alright, the moonlight docs is ass ngl
This? 
yeah that lol
Yep it is cursed alright 
part of why I'm considering all the cursed proxy-forcing options
The best way to go about it is somehow sandboxing the network and capturing all of the request to the proxy
But we know sandbox require some root privilege
tbh I have no idea what you can do in an appimage file
GamerSupps - https://gamersupps.gg/jaden10 (10% OFF)
Patreon - https://www.patreon.com/jadenwilliams
Merch - https://www.jadenw.com
Socials -
➤ Website - https://www.jadenw.com
➤ Main Channel - https://www.youtube.com/@Officialjadenwilliams
➤ Gaming Channel - https://www.youtube.com/@GamingJadenWilliams
➤ Tiktok - https://ww...
I think it's just FS sandboxing
Yep
imo my best bet is probably to try recompiling moonlight without disabling proxies first
But that's not a switchable compile options
I can just fork it I think?
Not from what I've read anyway
I think making a simple tcp proxy would be easier ngl
like the client updates so rarely I don't really care about "maintaining" a private fork
yeah true
if ssh can port forward udp and work through a proxy then I might be able to use it
Yeah, you can create SOCKS proxy through SSH tunnel
But you can also do reverse tunnel
Wait, have you tried reverse tunnel?
I haven't tried anything quite yet because my internet is a pain in the ass here
so I want some idea of what I'm gonna do before I do it
keep in mind ssh will need to access the internet through tailscaled 😭
I used to do some cursed stuff with reverse tunneling like changing setting on my ISP router at home from somewhere 
So more overhead 
moonlight is pretty resilient
Now I know exactly how vedal feels when working on neuro... Even though gary knows how to read, he tried everything but to place anything over that exact position 
Well, at least Neuro is honest now and say it clearly. Because it's funny lmao
True. Neuro is always right 
To be fair to gary, I have to improve the context given by the messages. They could always be better
shpere
Chay, do you know where they store the sfx assets for GrapheneOS image?
which sfx
Phone dialing tone
um no idea its probably the default android sounds anyway
Good one... I have to note myself to say "Circle" instead, probably... thanks
Yeah, I just asked since you used Graphene maybe you'd know the layout of the installation image too. Thanks anyway
i have not used graphene
never owned a pixel
I thought you said you use graphene? Am I imagining things?
i use linux on my phone
OHHH
How does Neuro sama works? Are the dialogue entirely generated by a custom LLM or does it sometimes have a custom dialogue injected in by a human?
We don't know
vedal is personally writing every line
No one knows... but you could imagine everything she says is entirely generated by an LLM
We may speculate but that's it
Unless you count "custom dialogue" as discord direct messages
The fastest OSU player surely must have the fastest WPM
Even the filtered ones? Wow, he's got hands
he writes the lines with one hand and slaps that hand with the another whenever he types something bad
Vedal lore just keeps getting more and more interesting
on the topic of nextjs, i wasn't trying to defend it then but i started a project and i want to now
I myself still adamant on JSX
i unironically love that it allows me to write spaghetti of whatever caliber i want
it reminds me of cpp in a sense
bless server actions
That’s not what I meant though 😭 I was just speculating if there are humans intervention in some cases to make it a better experience
Because some are just a bit too
Clipfarmy
Neuro does have control panel yes. It is a web based application that is protected with cloudflare zero trust
I saw it from one of the stream but I do not know how much it has evolved since
Is it okay to post the link?
I'll wait until there's a confirmation from mod/vedal employee anyway 
i don't think vedal is personally interacting with the ai in real time. probably just looking over the responses sometimes to filter them. but now even that is automated.
the clipfarmy parts are likely just the AI fetching memories and trying to be entertaining. thats kinda the point of neuro afterall 
Well at least vedal has some control to toggle filter
Hmm yes I guess that makes
Since ive read neuro have unlimited access to its past conversations and stuff
That is a recent addition
<Modal
button={{
color: user.verified ? "success" : "danger",
children: user.verified ?
<><Check size={18} /> Yes</> :
<><X size={18} /> No</>,
}}
>
<div className="max-w-xs">
<Heading h={3} className="mb-3">
Are you sure you want to{" "}
{user.verified ? "unverify" : "verify"} {user.name}?
</Heading>
<form
action={async () => {
"use server";
await toggleVerified(user.id);
}}
>
<Button type="submit">
<Check size={18} />
Yes, I'm {user.verified ? "taking away" : "granting"}
verification status of {user.name}
</Button>
</form>
</div>
</Modal>
``` this is real code for a admin panel i've written and shipped (it is in prod rn), don't you love this pattern 
assuming it was saved. and it can find it
i doubt the AI remembers everything all the time. i'd assume (very rough assumption), he got somekind of MCP or RAG setup for the memory
it updates in real time because the server action revalidates the path and that refetches the data sources
i like this. seems very nice to work with.
vedal does DM neuro or evil when he e.g. wants them to get back on topic but clip farming is entirely their own doing
Good, now another requirement just come in to add i18n
obviously theres also intervention in the form of filtering certain stuff or adding certain stuff to memories
("memory" is most likely not a single system anyway)
Assuming it as a a blackbox, it is 
Every AI or algorithm is a sort of black box anyways aint they
Depending on how you define it I guess
it looks nice in examples, is easy to write, but isn't great to maintain on a large scale - i did ok here by having a separate function toggleVerified but like, the idea that you can invoke any backend code in any seemingly frontend context- seemingly because technically no you can't, it's code executed server side only because react server components - but that's relatively new (not many people have rewired their brain to think of react code as server only) and still doesn't change the fact that you can attach backend code to user actions so easily and that makes you think less about the implications/makes catching dumb and dangerous shit at code review much harder
man I have so many things that I wanted to do
and I'm sure I can't finish them within the holidays 
I really need to make a todo-list thing for all my dumb shits and gave-up(suspended) projects
hblang might be usable for gamedev now
we should make an operating system out of hblang
funny you should mention
hblang is the os language for ableos
My favorite things to do using function pointer is changing the function being called on the fly 

thats how i od my graphics settings
how does an OS work without pointers
it just does

it has pointers 
Function pointer specifically. So it could still use some other method
like even this works
// inconspicuous-server-code.ts
"use server";
export async function makeDatabaseFaster() {
await sql`DROP TABLE "users";`;
}
// client-side-code.tsx
"use client";
import { makeDatabaseFaster } from "./inconspicuous-server-code";
export OptimizerReactComponent() {
return <button
onClick={async () => {
await makeDatabaseFaster();
alert("Optimization complete");
})
>
Optimize
</button>
}
it's very implicit that a given interaction will execute code on the server; when you're doing api routes you at least add an endpoint and that gets caught easily, this? good luck
why wouldnt it have pointers
metaprogramming bro... tell chatgpt that for 1hr glazing session
hm?
hblang abi? 
Yes and no?
hblang has a set abi
since hbvm has a set abi, and for it uses systemv abi on linux
oh yeah the whole os thing
(for c ffi)
mhm
working on finding some function ptr bugs
about to create a dynamic object
I can't read rust what is all this
its not rust
bieispbhshoaw
its hblang
ohh you mean the original compiler
hblang lives here
https://git.ablecorp.eu/mlokis/hblang/
Honestly, most of the time I use it for simple case like this
#include <stdio.h>
void function1(void)
{
printf("function1\n");
}
void function2(void)
{
printf("function2\n");
}
int main(void)
{
void (*ptr_to_fun)(void);
ptr_to_fun = &function2;
ptr_to_fun();
ptr_to_fun = &function1;
ptr_to_fun();
return 0;
}
yes you can do this in hblang now
I don't think I can read zig either
words cannot express how much i hate this

it indeed does suck
spend like a day with zig and you will be able to
reasons we have dynobject conventions and vtables
i will say, reassigning fn pointers is nice for runtime selection for vectorised implementations 
but that's only once obv
Yeah, I use it for something that needs to happen once in a while too to select which function to run in a tight loop
ooh I didn't realise but it looks like tailscaled supports socks5 udp
so that's like mildly less of a hassle
that's... a statement
one could say, it's a combination of words
nvm it's kotlin + c
my brain ain't braining at 2am
I'm heading to bed

gn

so I think my current best plan is to make my own "proxy" that acts like a moonlight-compatible device but actually forwards all traffic through tailscale
because then I can properly use the featureset of socks5 that tailscale supports and don't have to hack (much) of moonlight-qt
so like moonlight-qt < - tcp & udp - > my "proxy" < - socks5 tcp & udp - > tailscaled < - ... - > the rest of the magic
wait does moonlight use tcp too
both tcp and udp
iirc its tcp for the handshaking stuff (and maybe inputs?) and udp for the video stream
Mhmm, standard stuff
Mumble uses the same scheme. Tcp for handshake and control channel, udp for low latency audio
I don't actually know if it uses tcp for inputs
but I do know that if you scroll really fast it delays the mouse inputs 😭
Well, I mean control as in, muting, deafen, channel change, I think the text message is also done on TCP?, but audio and even positional audio with supported game plugins is through udp
Been a while since I read on their protocol
fair
mumble is neat but I've never really used it
and the one time I was going to use it recently we made a last minute decision to ditch it
because the IOS client was too broken and kept crashing
Yeah, it's the ol reliable for me. I made a compatible client for some MCU once
fixing a bug must require steady hands given how small some are


theres a saying "to [horse]shoe a flea" in russian
Mhmm, I'm lucky to not need apple support. There was a web client once, but I think it's quite abandoned now. There was a team to try and maintain said project. I don't know how the state of it is now. But given how the mumble protocol hasn't changed much, I think apple user can use the web instead
mhm
DynObj := struct {
.v_func: fn(^never): u8;
.obj: ^never;
$func := fn(self: ^DynObj): u8 {
return self.v_func(self.obj)
}
$new := fn(obj: @Any()): DynObj {
return .(@bit_cast(&obj.func), @bit_cast(obj))
}
}
Obj := struct {
.state: u8;
func := fn(self: ^Obj): u8 return self.state + 1
}
main := fn(): u8 {
obj := Obj.(255)
dyn_obj := DynObj.new(&obj)
return dyn_obj.func()
}
it doesnt work yet, but im hoping it will soon
what is that monstrosity of a syntax
hblang in its full glory
why is it never instead of void
makes me feel safer
it makes me feel unsafer
// ...
Obj2 := struct {
.state: u8;
func := fn(self: ^Obj2): u8 return self.state - 1
}
main := fn(): u8 {
// ...
obj2 := Obj2.(1)
dyn_obj2 := DynObj.new(&obj2)
return dyn_obj.func() + dyn_obj2.func()
}
theoretically this would also work which is what im excited to test
its really a waste for small functions of course 
i think its confusing personally
you probably just lack experience
hblang is directly compiled to x86/target architecture right?
i just like readablity instead of random symbols..
$what := fn(x: ^never): never {
return x.*
}
main := fn(): never {
return what(@bit_cast(&0))
}
surely no one would ever do this 
x86_64 or hbvm
directly, yes
go to java 
im learning rust rightnow...
as always, it's a matter of familiarity 

i'd argue there is some rust code that is just objectively ugly af
but that's like 2% of it
like my code 
the one thing that i still have trouble with is. that you can just have a random variable as the last line of a function and it just works
not variable but expression 
strings 
isn't this a variable...
You all have not met ERF

fn collect_msgs<T>(receiver: &mut UnboundedReceiver<T>) -> Vec<T> {
std::iter::from_fn(|| receiver.try_next().ok().flatten()).collect()
}
Technically, it is a statement

it is not
does anyone have that "x is for delusional ppl" meme but with rust
Alright, expression

just remember, any {} block returns a value, that value being the last expression in the block 
including functions
i mean... yeah...
I am too sleep deprived to explain things
there's also nothing stopping you from just doing return messages; (pls don't crucify me chay)
its just weird being able to just have something as the last thing. instead of it being empty or with a return statement
takes some getting used to for sure, but it does offer some nice things
It's just another concept that you need to be familiar with
its not a big thing
just was odd
like not needing an extra syntax for ternaries
Sounds similar to some aspects of js
i also should probably disable inlay hints... they are making it harder to read i think
i usually turn them off but i know a lot of people like to keep them on for seeing the intermediate types
useless braces
i know... let me be. im rewriting my cpp code in rust and just want it to work

every function i wrote is still technically "unused" since i haven't tested anything yet
maybe i should actually connect things up and just see if it atleast runs...
naaah it typechecks surely its fine
if it builds it must run 

glDrawArraysInstanced(GL_TRIANGLE_STRIP, 0, 5, 1000000);
1 million instances 
Sam next logical step is rust
inlay hints mentioned
no?
rust doesnt run on the gpu
Oh, he shows up
rust uses llvm
Neither does C technically
llvm can target nvptx so it runs on the gpu 
actually
does rust expose llvm intrinsics in any form
yep, but vulkan does
#programming message mandatory posting
Wtf
Compiler intrinsics.
can it run my shaders tho?
i mean... you can write everything in rust that you can write in C or c++
so yes you can write gpu code
I basically made a massive set of generics to control an application
Its kinda different a bit
so everything was typechecked and extensible
at the slight cost of insane generic signatures
LSP stress test
i am personally an inlay hint enjoyer, and yes,
this is good actually
ah i figured as much, sadge
but i guess it's rust so makes sense
its good but it does not need to be a multiline inlay hint 
it needs to be as descriptive as it can be 
just look at how clean the result was
(there are totally not a metric fuckton of other lines that completely negate a lot of this cleanliness)
honestly.. i've roughly been working on this cpp => rust project for like a week. and i do start to enjoy rust a bit. tho i don't like how restrictive the compiler is sometimes. (but i guess thats kinda the point of rust
)
everytime i start the game engine the twitch stream im watching freezes the video and i have to reload the page 
dyn objects are working
I am now too scared to ask. Did GPU program not have some sort of protection between them?
Or is it because of the browser?
that can happen when there's not enough resource to decode the video, and eventually the renderer just gives up
so my pc gives full priority to opengl ig?
i mean.. i'd assume the gpu has its own scheduler. so a game or a program will take priority over something like a browser
demo
not sure what the best usecase would be in lily though
perhaps some DynAllocator, DynHasher, etc
for deduplicating some code
Normal gradle things
reasonable response to gradle
a a a a
generally its not used that often
but obviously for something like kernel modules its a must
for low throughput and high variance
if you do not do this while doing gradle, you are not doing gradle
makes sense
struggling to think of the immediate usecase except for things like callbacks
schedulers perhaps
good point its good for type erasure
yeh
async in particular
Future(T) would be a convenient dynobject
Box<dyn Future>
what are you planning to do with the function ptr type
im curious
have you looked at how many lsp commands there are
nope 
oki poki
have you seen rpc.hb
nope 
good

its a file full of just struct definitions
lovely
hang on let me check if i can do overload arguments with this
i cannot
bwaa
awab
no way of checking if function has an arg or not
mhm thats what i complained about a while ago, no way to get function arity or its argument types
Reflections 
i was hoping @len_of() or @has_decl() or indexing would work on fptrs but uh
yeah
perhaps on @TypeOf(&func)
but doubtful
awa
i think it makes sense to keep a DynAllocator in alloc.hb because it serves as an up-to-date representation of the allocator api

its also convenient for small things
what would a DynAllocator be for, isn't the normal allocator already pretty damn generic 
takes_alloc := fn(alloc: DynAllocator): []u8 {
return alloc.alloc(u8, 100) || &.[]
}
main := fn(): void {
// weep woop
x := takes_alloc(DynAllocator.new(&arena))
y := takes_alloc(DynAllocator.new(&slab))
// etc
}
i use arena and noop (always returns null) allocators, theres also the heap allocator
takes_alloc doesnt need to be monomorphised if you use dynamic objects
when you dont have something like rust its more convenient to not use regular malloc/free everywhere but use specialized storage strategies
oh i know 
mhm and theres no interfaces in hblang, only @Any() and thoughts and prayers
DynObj := struct {
.v_func: ^fn(^void): u8;
.obj: ^void
$func := fn(self: ^DynObj): u8 {
return self.v_func(self.obj)
}
$new := fn(obj: @Any()): DynObj {
T := @TypeOf(obj.*)
fptr := @as(^fn(^T): u8, &T.func)
return .(@bit_cast(fptr), @bit_cast(obj))
}
}
Obj := struct {
.state: u8
func := fn(self: ^Obj): u8 return self.state + 1
}
yeh, mild inconvenience when setting one up, but as you can see, only the new function is generic, dynamic dispatch is used for other bits
Man, 2.4GHz band needs to be nuked
that would be a pretty big explosion
yeh
@Any() is supposed to actually be @Any(<func> | <type>, <type>, ...)
takes_alloc := fn(alloc: @Any(is_allocator)): []u8 {
return alloc.alloc(u8, 100) || &.
}
is_allocator := fn($T: type): bool { return false }
// ...
i see
of course its unimplemented
however @Any() still takes arbitrary arguments
(even if they are no-op)
fn(alloc: lily.alloc.AnyAllocator): void {}
fn(alloc: @Any()): void {}
one makes you feel safer

will be adding DynAllocator to this list
and then you have the choice between monomorphisation and dynamic dispatch without a change to the interface
DynAllocator := struct {
.alloc: ^fn(^void, $T: type)
}
i have encountered the first problem 
somehow i do not think this is going to work 
i did suggest you to switch it to alignment+size layouts before
and use typed APIs as wrappers around those
good luck 

i got used to just randomly renaming stuff when the compiler complains
i have surpassed the second problem
it used to complain much more
but i still have T1 everywhere instead of T in json.hb
im considering changing dealloc to just accept a ptr instead of a ptr and a length
damn this shader ugyl as fuck
probably safe to copy this https://doc.rust-lang.org/std/alloc/struct.Global.html
The global memory allocator.
does it ever make sense to change the align of an existing allocation
seems dubious to me
while it does not, it does not make sense to make the allocator store it
yeah, i agree
without dependent types you pretty much just have to say "this should be the same not like i can prove that"
unsafe fn grow(
&self,
ptr: NonNull<u8>,
old_layout: Layout,
new_layout: Layout,
) -> Result<NonNull<[u8]>, AllocError>
rust uses this
which is interesting
i think i will elect to do this:
.resize: ^fn(^void, ^u8, mem.Layout, uint): ?[]u8;
mhm
note that they dont pass allocation size other than the layout
the layout serves as both
yeah
speaking of, i should probably make it return Result huh
vaguely annoying
will be cost free when tagged unions
you dont have to since nullptrs are undefined behavior
reason for alloc error is vaguely useful tho
just make it return ?^void
Define it 
no 
?[]u8 is more useful imo
that should be already known as part of the layout
in the case that
alloc(100, u8) -> [50]u8
then i suppose you will just retry allocation anyway
hm
no you dont retry this just should not ever happen
it should return what was asked of it or null
The construction of mat3 is not symmetric 
hum
hence ^void
void over u8 mhm
whatever works 
while im here
you can alternatively look at https://github.com/ziglang/zig/blob/master/lib/std/mem/Allocator.zig
alloc, alloc_zeroed, dealloc, resize, anything ideas for other things?
but what is this
funny
erm i mean this should be enouhgh
tracing where allocation came from?
vaguely useful for dynamic analysis maybe
or for doing unspeakable things to objects depending on their lineage
but why did they use usize and not ?*void
i wonder why zig returns a slice
?[*]u8 is an optional slice
possibly just flexibility reasons
you're allocating memory, why wouldn't you return a slice
arbitrary design choice
how else would you represent a chunk of memory
imo its bad that it returns a slice because it allows the API to return something with length other than len
by making it only return the pointer you remove the potential for depending on the returned length being somewhat different from the len in arguments
and the caller has len either way as they provided it
hmm
this is interface design 101
dont expose anything beyond the bare minimum or it will be depended on
ret := alloc(100)
if ret == null die
if ret.?.len < 100 die
imo its mainly ergonomics. provided your allocation was undersized you are likely to redo the allocation anyway
imo ergonomics are to be provided by a higher level wrapper
even disregarding the "allocator should never do this" standpoint
i guess there's nothing stopping you from doing so
this is not ergonomics this is a bad allocator 
general userspace allocators have different requirements to systems allocators
system allocator failing is catastrophic, cant do much about that
system allocators dont do "give me some memory up to N bytes" either, they do "give me exactly N bytes"
and so do userspace allocators
so if ret.?.len < 100 ever runs its a bad allocator
so it makes sense to remove the ability to write allocators like that by making them not return slices
i believe you may have misread what i said, i didnt say it was a good design choice 

awb
speaking of arbitrary design choices
init or new
create 
imo it makes sense for init to intiialize existing objects and new to create new objects
create is longer than new rejected
i think the clear answer is to copy the name of the struct 
very usable
A := arena.create()
B := arena.new()
arbitrary naming choice is always the hardest
deciding create has too many chars
imm aneed to watch the acerola grass video again, my grass sucks
wait is it for allocation?
or for creating new arenas



thank you language nerd

its working again
i think it's actually fine





peak thumbnail in my recommended





