Guild icon
DDraceNetwork
DDraceNetwork / off-topic
Any languages allowed
Between 2025-02-16 00:00 and 2025-02-17 00:00
Avatar
s I lov
Avatar
does gentoo compile kernel too
Avatar
@meloƞ why didn't anyone told me about nix-direnv
Avatar
Avatar
TsPiggy
does gentoo compile kernel too
ofc it compiles everything brother
08:07
08:07
gotta update
Avatar
Avatar
Ryozuki
ofc it compiles everything brother
epic
Avatar
Avatar
TsPiggy
@meloƞ why didn't anyone told me about nix-direnv
lmao you did
Avatar
Avatar
TsPiggy
@meloƞ why didn't anyone told me about nix-direnv
I'm 1000% sure I did.
Avatar
Avatar
TsPiggy
lmao you did
saddybear
09:31
it's like one line in a pile of text dump
09:31
but you did mention it (edited)
09:34
who maintains ddnet's nixpkg
Avatar
Avatar
TsPiggy
who maintains ddnet's nixpkg
Currently me
Avatar
you again
Avatar
I should probably bump it again justatest
Avatar
Avatar
meloƞ
I should probably bump it again justatest
it's like you've read my mind
09:35
Can't you just bump it for me
09:35
monkalaugh
Avatar
if i know how
09:36
is it not possible to have it auto bump or something?
Avatar
Avatar
TsPiggy
is it not possible to have it auto bump or something?
We could, but that could theoretically break all packages when 1 dep lands on a broken version
09:39
i see the nix file, but i don't know how to even get a hash
09:39
nix is weird
09:39
plus i never tried building a nixpkg myself
Avatar
You clone the nixpkgs repository (that's the annoying part)
Avatar
Avatar
meloƞ
You clone the nixpkgs repository (that's the annoying part)
i can see that
Avatar
On the top level flake.nix - you go into the dev env Then nix build -A ddnet which will build ddnet
Avatar
flatpak does it just by auto creating repos
Avatar
Easiest way to get hash Is to change version and remove hash, the build will fail with the expected hash
Avatar
can i still PR if --depth 1
09:42
i imagine I can, never tried it
Avatar
justatest no idea tbh
Avatar
there is no way you need to download the entire history of nixpkgs just to maintain something
09:43
that's insane
Avatar
Avatar
TsPiggy
there is no way you need to download the entire history of nixpkgs just to maintain something
saddybear
Avatar
what is this https://github.com/NixOS/nixpkgs/pull/382523 nixpkgs-update thing
Avatar
Nixpkgs-review?
Avatar
Automatic update generated by nixpkgs-update tools. This update was made based on information from passthru.updateScript.
Avatar
Ah, lol?
09:45
Never used that
Avatar
sounds like it is possible to auto generate PR
Avatar
It updates based on commit rev instead of release tag
09:45
Interesting
Avatar
i imagine you can config that
09:46
also probably unstable should be one nightly and stable on release. if it can be automatically done
09:47
InsaneCat
09:47
https://nix-community.github.io/nixpkgs-update/
The nixpkgs-update mission is to make nixpkgs the most up-to-date repository of software in the world by the most ridiculous margin possible.
so arch
09:48
cba to learn this rn tbh. (edited)
Avatar
Avatar
TsPiggy
cba to learn this rn tbh. (edited)
kekw
Avatar
https://nix-community.github.io/nixpkgs-update/nixpkgs-maintainer-faq/#nixpkgs-maintainer-faq
@r-ryantm opened a PR for my package, what do I do?
so it really just auto pr for you
09:50
r-ryantm gets its new version information from three sources: Repology - information from Repology is delayed because it only updates when there is an unstable channel release GitHub releases package passthru.updateScript
so it feels like we could just set something up and the bot just updates them. you still need to review them tho
Avatar
my firefox crashes a lot more frequently lately
Avatar
Is there something like man but for custom notes?
10:38
I guess it's just a text editor
10:38
And a place to store notes
10:38
But
10:39
I specifically want something where i can write how to use certain commands
10:39
Because i forget every time
10:41
I guess it should be easy to create such program from scratch
Avatar
Avatar
pilonpl
Click to see attachment 🖼️
Avatar
playing games while coding youtube
Avatar
i am trying to make an assembler in C
11:02
it's quite complicated
11:03
i think i need dynamic arrays
11:04
to store tokens
11:05
and other stuff
11:05
because i think the way i should do it
11:05
is that i know which tokens are one instruction
11:06
so i group the together
11:06
and then i can have rules
11:06
which can match with the structure of the instruction
11:07
so for example i can have a rule that the first "operand" has to be the type of INSTRUCTION_ADD
11:07
or something like that
11:10
this makes it possible to assemble one instruction into multiple things based on how many operands are present and what types they are
Avatar
Avatar
pilonpl
I specifically want something where i can write how to use certain commands
There's this cool advanced feature that many computer software stacks have called a file system :P
Avatar
yeah
11:24
but it's hard to use
11:24
i would have to type /the/path/to/the/file.txt every time
11:24
or have a variable i guess
Avatar
@TsPiggy i can fetch raw json from https://ddnet.org/players/?json2=meloƞ kekw
11:25
api testing tool done - when next project?
11:25
justatest
Avatar
such a quick project lmao
KEKW 1
Avatar
but it's still better to have some program that opens the correct file without much boilerplate
Avatar
Avatar
meloƞ
api testing tool done - when next project?
can you help deen to make our api faster. every request to that players/?json2 endpoint take half a second at least
Avatar
which api - ddnet.orgs ?
Avatar
i think deen has dedicated script for dynamic endpoints, everything else was static (edited)
11:27
although, for some reason even static pages like https://ddnet.org/ranks is super slow. it was configured to not caching in cloudflare for some reason
11:27
maybe for the last finishes data, but that doesn't really update too
Avatar
Avatar
pilonpl
but it's still better to have some program that opens the correct file without much boilerplate
make an alias alias notes="cd ~/notes ; vim" (edited)
Avatar
but i think i need more something like note notename
Avatar
why not just make a vim alias that automatically opens the directory?
Avatar
then notes something would open ~/notes/something in vim
Avatar
<leader>no(tes) or smth
Avatar
Avatar
meloƞ
why not just make a vim alias that automatically opens the directory?
I'm not the kind of person who lives in vim, I live in the terminal and commonly open vim
Avatar
lmao - ask @Teero
11:30
if you ask him what terminal he uses, he'll say neovim
Avatar
Avatar
TsPiggy
although, for some reason even static pages like https://ddnet.org/ranks is super slow. it was configured to not caching in cloudflare for some reason
not sure how much i could improve something thats not caching
Avatar
i should probably learn vim motions
Avatar
Avatar
meloƞ
not sure how much i could improve something thats not caching
make deen give you cloudflare admin panel
justatest 1
Avatar
(n)vim to me is a text editor, not an IDE
Avatar
Avatar
TsPiggy
make deen give you cloudflare admin panel
i'm fairly sure he'd rather give it to you :p
Avatar
but oh what a text editor it is
11:32
so good
Avatar
why would he do that. i'm chinese
Avatar
neovim is a text editor on crack
11:32
emacs is a desktop environment
Avatar
you don't give chinese things
Avatar
Avatar
TsPiggy
you don't give chinese things
i'd say deen trusts you more than others :p
Avatar
Avatar
meloƞ
emacs is a desktop environment
a good operating system sadly lacking a decent text editor
Avatar
Avatar
risu
a good operating system sadly lacking a decent text editor
fr
11:33
i tried doom emacs and had a lot of fun. an editor in which you could have a music player and anime running in the same window
Avatar
you can run emacs as your init
Avatar
you usually run emacs as a daemon anyway
Avatar
greenthing that is fair. i don't know why that is.
11:33
but i also don't want to change something that currently works. it is slow but it does work
11:33
it seems like as soon as i touch something, it will break
kek 1
Avatar
you can also run emacs as a window manager https://github.com/emacs-exwm/exwm
Emacs X Window Manager. Contribute to emacs-exwm/exwm development by creating an account on GitHub.
11:34
god i love emacs
11:34
i wish i learned that instead of vim
Avatar
at least you probably still have functional pinkeys
Avatar
and at this point the only motivation for me to improve ddnet.org is how slow teeworlds.cn is. which isn't really the correct motivation to improve ddnet
Avatar
so that's a silver lining
Avatar
imagine learning vim on colemak and giving up, definitely not me doing it 5 times (edited)
Avatar
Avatar
risu
at least you probably still have functional pinkeys
that is true, emacs using <C> and <M> to an extend that your pinkie will fall off when you're 35
Avatar
Avatar
TsPiggy
imagine learning vim on colemak and giving up, definitely not me doing it 5 times (edited)
there are remaps for custom layouts
11:35
i used the neo layout, which had an awesome remap for vim
Avatar
i mean ye, but i'll truly have to learn vim instead of googling things
kek 1
Avatar
i couldnt get used to it sadly, to much work
Avatar
Avatar
meloƞ
that is true, emacs using <C> and <M> to an extend that your pinkie will fall off when you're 35
You hit Alt with pinkey?!
Avatar
also remapping insert is kinda sinful
Avatar
Avatar
risu
You hit Alt with pinkey?!
._.
Avatar
my old colemak remap maps R as inseRt. it is so cursed
Avatar
Avatar
TsPiggy
my old colemak remap maps R as inseRt. it is so cursed
whaaatdafak
Avatar
cus my HNEI is your HJKL
Avatar
I think you could keep everything the same as long as HJKL gets remapped to the correct location
Avatar
i have to use I for navigation
Avatar
@TsPiggy for things like raw json fetching (goat related) would you display the raw response or beautify it a bit?
Avatar
oof I not being I feels so weird
Avatar
Avatar
meloƞ
@TsPiggy for things like raw json fetching (goat related) would you display the raw response or beautify it a bit?
most api tester reads content-type and decide what to do
Avatar
i would've just done certain things for a certain type of header
Avatar
Avatar
risu
I think you could keep everything the same as long as HJKL gets remapped to the correct location
ye that's exactly why colemak is hard for vim
Avatar
I'd probably just switch the binds J <-> N, K <-> E, L <-> I (edited)
Avatar
Avatar
meloƞ
i would've just done certain things for a certain type of header
honestly i would just pipe all headers down the frontend and let frontend do the header parsing so the frontend itself handles what format to display them in
Avatar
i see - yeah makes sense
11:39
how do i properly test different headers...
Avatar
keep the rest the same because they're mnemonic and you only have to memorize the three swaps
Avatar
time for some curl magic
Avatar
Avatar
risu
I'd probably just switch the binds J <-> N, K <-> E, L <-> I (edited)
that makes a little bit sense other than L is located at your U. right besides your I.
11:40
which is also kinda cursed that it shifted like one position it is soooo close
11:40
i honestly think vim on colemak just doesn't really hit me the same way
Avatar
Clearly we should use hex
Avatar
i've tried 5 times already
Avatar
wait what was that editor called?
Avatar
Avatar
risu
wait what was that editor called?
helix ?
Avatar
Helix yeah
Avatar
helix is awesome
11:41
but its not hackable
11:41
so it sucks
Avatar
I was confusing it with Hex the Minecraft mod
Avatar
i'll stick with vscode for now like a pleb
11:41
kekw
KEKW 1
Avatar
thats fair - idk vsc gets in my way
Avatar
Helix is "that other modal text editor" Hex is "that other programming magic mod"
Avatar
neovim navigation is just far superior imo
Avatar
They're also both purple themed :D
justatest 1
Avatar
helix with the aya theme
11:42
butiful
Avatar
vsc has been good for me until i switched to nixos
Avatar
Nvim needs way too much config to be useable
Avatar
BLYAAAAAAAAAAAAAAAAAAAAAAT
Avatar
the default key binds are different from windows and the electron window might be blank from time to time
Avatar
Avatar
pilonpl
Nvim needs way too much config to be useable
why you think that :o a single remap of netrw to a sane keybind, maybe telescope and thats it lsp and TS for fancy highlighting
Avatar
oh damn i forgot to check whether jetbrains has linux versions
11:44
they probably do since JAVA
Avatar
i think people underestimate how good stock neovim is
Avatar
they absolutely do
Avatar
need to check whether it is crackable in linux tho
11:44
probably is
11:44
i like jetbrains for gamedev
Avatar
pacman -S intellij-idea-community-edition moment
Avatar
well i don't use idea
Avatar
yeah fuck idea
Avatar
jetbrains has rider for unity ue and godot (edited)
11:45
at this point rider has more language support than idea with plugins
11:45
the fucker does C/C++/C#/typescript/gdscript at the same time
Avatar
well there seems to be the rider AUR package but it's less cool when it's not in the official repos
Avatar
i can't use AUR anyway
Avatar
dont you have chinese mirrors?
Avatar
i mean, can you just use AUR on nix
11:46
justatest
Avatar
ah - nah its prebuild binaries
11:46
i mean yeah you could
11:46
but it requires LD magic
Avatar
i don't mind ld
11:46
i already used nix-ld for blockhead (edited)
Avatar
just get one and see if makepkg -i makes your pc go boom
11:47
not sure how reliable it is in terms of dependencies etc
Avatar
i mean
11:47
fuck AUR. we got nixpkgs
Avatar
Isn't Nix the thing that allows you to get packages from all over the place? I thought they'd be fine with all sorts of messy things that have been repackaged three times
Avatar
makes sense
Avatar
Avatar
risu
Isn't Nix the thing that allows you to get packages from all over the place? I thought they'd be fine with all sorts of messy things that have been repackaged three times
yeah no, nixpkgs tries to stay fully pure to the /nix/store
11:48
thats why prebuild binaries wont run by default
Avatar
Avatar
Ryozuki
Click to see attachment 🖼️
@Learath2
Avatar
Avatar
meloƞ
makes sense
and Ubuntu is cheating because they split everything into a million pieces
Avatar
nix kinda don't let you get package from anywhere other than a nix enabled place
11:49
probably why they tried so hard to package everything too tho
11:49
cuz otherwise it's a PITA to run anything
Avatar
good thing is, if you have any sort of project
Avatar
most every ffmpeg lib for example is its own package, while on Arch it's just ffmpeg, and that contains the dev stuff too
Avatar
just put in a flake.nix and people can use nix to grab it
Avatar
Avatar
risu
most every ffmpeg lib for example is its own package, while on Arch it's just ffmpeg, and that contains the dev stuff too
Avatar
is the a flake nix generator for crates
Avatar
Avatar
Ryozuki
is the a flake nix generator for crates
crate2nix
Avatar
does it work
11:52
with
11:52
external c deps
Avatar
Avatar
meloƞ
yeah no, nixpkgs tries to stay fully pure to the /nix/store
Wait, so what was the OS/package manager that let you combine packages from different distros?
Avatar
i dont remember ever building something that was dependent on external c
Avatar
i do all time
11:53
llvm
Avatar
Or is that Nix but it's just less flexible than I heard from the zealots?
Avatar
Avatar
meloƞ
good thing is, if you have any sort of project
the bad thing is, any random project you find won't have nix support
11:53
oh good http://jetbra.in/s still works
11:53
it probably does
Avatar
ah - well makes sense xD
Avatar
seems fine to me
11:53
china please
KEKW 1
Avatar
Avatar
meloƞ
why you think that :o a single remap of netrw to a sane keybind, maybe telescope and thats it lsp and TS for fancy highlighting
so can you just give me a config that's decent?
Avatar
Avatar
pilonpl
so can you just give me a config that's decent?
11:55
all my remaps. kekw
Avatar
i honestly think nix is just python conda for any environment.
11:55
i set it private
Avatar
don't public it
11:56
just in case you've made it private for "some reason" and you can't remember
11:56
that happens a lot to me and i leak my stuff
Avatar
its just .lua - nothing secret in there
Avatar
ye but lua file can have things in them justatest
Avatar
I wouldn't make my configs public simply because I don't feel the need to tell the world how my computer is set up
👍 1
11:57
(I'm also not super proud of how lazy everything is lol)
Avatar
and then there is the nix community
Avatar
i only public my nix config because melon needs to see it
Avatar
HEY LOOK HERE MY DOTFILES ON MY ENTIRE SYSTEM: https://github.com/BlaiZephyr/nix-dotfiles
❄️-dotfiles codeberg was fun boys, but we gitting now. - BlaiZephyr/nix-dotfiles
11:58
everything.
Avatar
imagine someone also setup ssh and gpg privkeys via hm and public their config too
Avatar
if you want my full neovim setup - just copy paste my config with nix kekw
Avatar
Avatar
TsPiggy
imagine someone also setup ssh and gpg privkeys via hm and public their config too
easy, you can handle secrets pretty well with nix
Avatar
Avatar
meloƞ
easy, you can handle secrets pretty well with nix
teach
Avatar
Avatar
TsPiggy
@Learath2
Sorry, that's beyond my current scope. Let's talk about something else
Avatar
I wish I didn't feel the need to use github... but like, they have all the things
Avatar
all private keys of scrumplex in plain sight...
Avatar
tf is scrumplex
Avatar
scrumplex is.. the one that introduced me to nix
11:59
you never read my dotfiles? :(
11:59
no
11:59
why would i
Avatar
he maintains the prism launcher AUR package i think
Avatar
Avatar
pilonpl
he maintains the prism launcher AUR package i think
indeed, he's also the main maintainer of prism launcher
Avatar
i just setup my git to autosign using a keyid in nix, and the next time i set it up it'll just scream at me that key doesn't exists so I manually add it (edited)
Avatar
Avatar
meloƞ
indeed, he's also the main maintainer of prism launcher
very cool
Avatar
i imagine that's how you would want it to be instead of commiting privkeys anywhere
Avatar
if you're not using a multimc-based launcher what are you even doing
Avatar
ok now
12:03
kekw do i want to make it public
12:03
@meloƞ that means i need to setup jetbrain cracking in my nix config....
12:04
bro wtf i have a pimple in my ear
12:04
it hurts so fucking bad
12:04
help
Avatar
Avatar
meloƞ
bro wtf i have a pimple in my ear
lobe or canal
Avatar
just outside the canal
12:05
i cant put my earphones in
12:05
feelsbadman
Avatar
use a over-ear i guess lmao
12:05
angeryping i keep getting pimple in my lower lobe
Avatar
is it better to have DynamicArray DynamicArray_new(...) or void DynamicArray_init(DynamicArray* array, ...)?
12:08
and there is also DynamicArray* DynamicArray_new(...)
12:08
there are so many options
Avatar
i wonder if i could port jetbrains cracking to a flake
12:10
and where i should even put it if i did
Avatar
Avatar
pilonpl
there are so many options
The first two are only possible if your type is not opaque. I tend to use the 3rd option you gave usually (edited)
Avatar
Avatar
Learath2
The first two are only possible if your type is not opaque. I tend to use the 3rd option you gave usually (edited)
yeah but i guess i don't need the DynamicArray struct on the heap, just the void* data portion of it
Avatar
Yeah but to have the first two you still need to leak the definition of DynamicArray so the user can allocate one
Avatar
isn't that how most things work anyways?
12:15
doesn't seem like a bad thing at all
12:16
and i am the only user anyways so it doesn't matter to me i guess
12:16
but for example in raylib there are many struct like that i think
Avatar
Well depends on your goals. In C libraries we like to keep things opaque. Like FILE e.g. FILE *fopen(...)
12:17
But sometimes you do want to allow the user to allocate himself. Then you just leak the details. The init function is usually of the second form you sent then
Avatar
i just now learned about opaque types lol
12:18
but yeah it makes sense
Avatar
I have also seen a weirder pattern where they leak only the size of the struct as a define. So you can allocate your own memory but very uncommon. I don't even remember where I saw it
Avatar
i could've just used cpp and std::vector
Avatar
Ah I saw it in pthread_mutex_t
Avatar
i wanted to learn about multithreading
12:24
but i guess it's not a standard C feature
Avatar
Avatar
risu
I'm not the kind of person who lives in vim, I live in the terminal and commonly open vim
I use nvim as my default shell
Avatar
Well technically C11 did standardize threading 😄
12:25
Idk anyone who uses C11 threads though
Avatar
i dont even know what i use
12:26
anything that works with clang lol
Avatar
Avatar
Learath2
Idk anyone who uses C11 threads though
(Mostly compiler vendors fault, gcc took 2 years to add it, msvc just added support in 2022)
Avatar
i still somehow don't know what size_t is
Avatar
Avatar
pilonpl
i still somehow don't know what size_t is
It's a type guaranteed to be able to hold the size of any theoretically possible object
Avatar
rust makes u a better C coder
12:39
@Learath2 agree?
Avatar
Avatar
Ryozuki
@Learath2 agree?
Hm, idk. Why do you think that's the case?
Avatar
the strong ownership system teaches u things about lifetimes in a more obvious way than C
12:42
so C devs benefit from this
12:42
the problem is that u might think u are doing something correct in C
12:42
because there is no error
12:42
so ur simply ignorant
Avatar
Avatar
Ryozuki
because there is no error
ubsan gives error
Avatar
not all stuff
12:43
i even strongly believe this to be even truer for ppl learning C
Avatar
Hm, but Rust's ownership and lifetimes hides the details from you. I don't think it's that easy to apply to C
Avatar
i guess rust is "if it compiles it works" lol
Avatar
Avatar
Learath2
Hm, but Rust's ownership and lifetimes hides the details from you. I don't think it's that easy to apply to C
wdym
Avatar
Avatar
Ryozuki
wdym
Rusts type system secretly protects you from the many footguns of C. You have raii to hold your hand. You have mostly automatic memory management
Avatar
do notei m talking about it making u a better C dev not a master
Avatar
Avatar
Learath2
Rusts type system secretly protects you from the many footguns of C. You have raii to hold your hand. You have mostly automatic memory management
yeah well thats mostly for leaks
Avatar
I'd say learning to think in terms of ownership is very useful, but that's about it
Avatar
it being so strong about these stuff helps a lot to learn
12:47
also about threading
12:47
and safety
Avatar
I'd still suggest a C first approach so there is no standard library to hold your hand
Avatar
Avatar
Learath2
I'd still suggest a C first approach so there is no standard library to hold your hand
idk u can reinvent the wheel in rust too
12:47
but i guess C to reinvent wheel to learn is ok
12:47
but to learn these more abstract stuff idk
Avatar
Avatar
Ryozuki
idk u can reinvent the wheel in rust too
But it suddenly becomes veeery hard. Implementing a doubly linked list is a huge exercise in figuring out who owns what
Avatar
a person learning programming in C doesnt know what a race condition is
12:48
and that they have to use atomics somewhere
12:48
or locks
Avatar
Avatar
Learath2
But it suddenly becomes veeery hard. Implementing a doubly linked list is a huge exercise in figuring out who owns what
always the stupid list, i guess if u love lists yeah
Avatar
Avatar
Ryozuki
also about threading
I can see it also being helpful in learning threading yeah. Send and Sync are pretty intuitive concepts
Avatar
but i would better teach making a vec
12:49
u can achieve a list easily disregarding perf a bit
12:49
using rc
Avatar
Avatar
Ryozuki
always the stupid list, i guess if u love lists yeah
Well if you hate lists so much, graphs are also tough (unless you are using an adjacency representation)
Avatar
why do i always start convos when im raiding
Avatar
Yo is it true that some algorithms can't be written properly in rust or are slower because of ownership limitations?
Avatar
Avatar
Ryozuki
why do i always start convos when im raiding
Do your raid, I need to eat food anyway 😄
Avatar
Avatar
Teero
Yo is it true that some algorithms can't be written properly in rust or are slower because of ownership limitations?
In safe rust, yes, I remember a couple cases. But you can always just drop down to unsafe and get the exact same performance you'd expect
Avatar
Avatar
Learath2
In safe rust, yes, I remember a couple cases. But you can always just drop down to unsafe and get the exact same performance you'd expect
feels like that's kinda missing the point of Rust, but then again I imagine most of the important algorithms would already be part of some carefully crafted library
12:58
it's like Haskell, it's supposedly pure but if you look into the parts that actually do anything they're kinda ugly at times
Avatar
Avatar
risu
feels like that's kinda missing the point of Rust, but then again I imagine most of the important algorithms would already be part of some carefully crafted library
This is why I don't like more modern languages when teaching. Everything is in a carefully crafted library so you end up with programmers that don't know how a hashmap or vec actually works
Avatar
Avatar
risu
feels like that's kinda missing the point of Rust, but then again I imagine most of the important algorithms would already be part of some carefully crafted library
Btw there is no issue with having to use unsafe rust. That's the point of unsafe, there are completely valid constructs that safe rust does not allow by design. To create a type system that can statically determine correct lifetimes there had to be compromises made or you hit the halting problem
Avatar
relating to my gripes with noVideo graphics yesterday, a lot of my problems appear to have fixed themselves overnight??
Avatar
If a human can decide that something is actually safe then why can't the compiler do it?
Avatar
and I guess a number of my issues were with the game launcher, because it displays Wine versions correctly now weird graphical bugs are gone now, that's the important part
Avatar
Avatar
pilonpl
If a human can decide that something is actually safe then why can't the compiler do it?
I imagine they just draw the line wherever they think is reasonable, because otherwise the compiler is going to get progressively slower and more complicated
13:06
as more ways of reasoning are added
Avatar
Avatar
pilonpl
If a human can decide that something is actually safe then why can't the compiler do it?
Usually because the human has external information that they can't describe to the compiler
Avatar
Avatar
risu
and I guess a number of my issues were with the game launcher, because it displays Wine versions correctly now weird graphical bugs are gone now, that's the important part
I think I'll try downgrading my drivers anyways as I'd like to get gamescope working again
13:08
Yuanshen kinda tends to throw a fit when tabbing out of it for more than a few seconds without gamescope
Avatar
Avatar
Teero
Yo is it true that some algorithms can't be written properly in rust or are slower because of ownership limitations?
no because u can use unsafe
13:09
but the borrow checker isnt perfect, it makes some valid programs not being able to compile
13:09
being perfect is not possible due to the halting problem i guess
13:09
but its getting better over time
13:09
NLL helped
13:10
soon there is a new trait solver
13:10
well its already in
13:10
and with the new trait solver they can improve the borrow checker easier
Avatar
I feel it's a bit lame from Rust zealots... "Our language has this magic superpower, you should use it!" "But what about <problem>?" "Just turn off the magic superpower!" kind of a bruh moment
13:11
Like, I get that it's a very powerful feature
13:12
but it's sold as if it's going to solve world hunger and resurrect Jesus
Avatar
To be fair, most rust users will pretty much never need to drop to unsafe ever
Avatar
All these things are in some carefully crafted library already thought of by dtolnay
Avatar
Avatar
risu
I feel it's a bit lame from Rust zealots... "Our language has this magic superpower, you should use it!" "But what about <problem>?" "Just turn off the magic superpower!" kind of a bruh moment
thats false, unsafe still has guarantees from rust that C doesnt
13:13
unsafe just allows u to deref pointers and 2 other things
13:13
Dereference a raw pointer Call an unsafe function or method Access or modify a mutable static variable Implement an unsafe trait Access fields of a union
13:13
thats all unsafe allows
13:13
u still have the same ownership system, and guarantees
Avatar
Avatar
Learath2
All these things are in some carefully crafted library already thought of by dtolnay
did u know dtolnay works at palantir
13:14
xd
Avatar
Avatar
Ryozuki
u still have the same ownership system, and guarantees
Well it allows you to craft two mutable references to one object. Which breaks a huge assumption by the borrow checker
Avatar
Avatar
Ryozuki
did u know dtolnay works at palantir
Whoa. I did not
Avatar
It’s important to understand that unsafe doesn’t turn off the borrow checker or disable any other of Rust’s safety checks: if you use a reference in unsafe code, it will still be checked. The unsafe keyword only gives you access to these five features that are then not checked by the compiler for memory safety. You’ll still get some degree of safety inside of an unsafe block. In addition, unsafe does not mean the code inside the block is necessarily dangerous or that it will definitely have memory safety problems: the intent is that as the programmer, you’ll ensure the code inside an unsafe block will access memory in a valid way.
Avatar
But makes sense, he is top talent. The man is a Rust virtuoso
Avatar
yeah
13:15
but some places in rust are a bit extremist
13:16
and palantir is... well a company a bit dubious
13:16
military us etc
13:16
xd
Avatar
I can imagine some rust people not liking that very much
Avatar
so some ppl dont like he works there xd
Avatar
I wonder if he has a turkish origin. His last name has an extremely turkish vibe (edited)
Avatar
Avatar
Learath2
In safe rust, yes, I remember a couple cases. But you can always just drop down to unsafe and get the exact same performance you'd expect
oh okay makes sense
Avatar
safe rust is in some cases more perfomant than C
13:19
because rust uses llvm noalias attributes always
13:19
as llvm gets better at noalias rust gains more perf too
13:19
as can be seen when they upgrade llvm versions
Avatar
Avatar
Ryozuki
safe rust is in some cases more perfomant than C
omw to embed assembly
Avatar
u can in rust too
Avatar
Oooh, I did not know dtolnay was involved in major drama
Avatar
Avatar
Ryozuki
u can in rust too
whoa? that's very cool
Avatar
The RustConf incident
Avatar
asm! macro
Avatar
like architecture specific assembly or LLVM IR?
13:22
or both? 👀
Avatar
Avatar
Ryozuki
because rust uses llvm noalias attributes always
Does llvm use the noalias attribute more nowadays? In the past iirc it only disabled a single optimization
Avatar
formatstring := STRING_LITERAL / RAW_STRING_LITERAL dir_spec := "in" / "out" / "lateout" / "inout" / "inlateout" reg_spec := <register class> / """ <explicit register> """ operand_expr := expr / "" / expr "=>" expr / expr "=>" "_" reg_operand := [ident "="] dir_spec "(" reg_spec ")" operand_expr / sym <path> / const <expr> clobber_abi := "clobber_abi(" <abi> *("," <abi>) [","] ")" option := "pure" / "nomem" / "readonly" / "preserves_flags" / "noreturn" / "nostack" / "att_syntax" / "raw" options := "options(" option *("," option) [","] ")" operand := reg_operand / clobber_abi / options asm := "asm!(" format_string *("," format_string) *("," operand) [","] ")" global_asm := "global_asm!(" format_string *("," format_string) *("," operand) [","] ")"
Avatar
how can assembly work with any language really?
13:26
linking it after compilation makes sense
13:26
but inline assembly?
Avatar
you just compile the rest as normal and then place the assembly in the appropriate spot
13:28
of course you can't really optimize that part very much
Avatar
this is a llvm intrinsic
Avatar
but how can you know anything about what registers stuff is in
Avatar
or idk what you would need to know
Avatar
Avatar
pilonpl
but how can you know anything about what registers stuff is in
calling convention
13:29
maybe with llvm magic you can ask the compiler? idk
Avatar
why is calling convetion the answer for everything
Avatar
it's the only way you achieve consistency at machine code level
Avatar
Avatar
pilonpl
but how can you know anything about what registers stuff is in
It's not exactly directly assembly. You have magic tokens that evaluate to the location of a variable
13:31
Like {x} can be used to refer to the rust variable x
Avatar
Avatar
Learath2
It's not exactly directly assembly. You have magic tokens that evaluate to the location of a variable
so I guessed right! you use llvm magic to ask the compiler!
Avatar
@meloƞ my firefox experience rn
Avatar
vibing
14:38
basically just updating to plasma 6.3...
Avatar
nothing else changed
Avatar
The world is soooo over
Avatar
Knowledge Workers
Avatar
Perhaps the invention of generative ai is one of the great filters
Avatar
Avatar
Learath2
The world is soooo over
get this. chinese does not even have the concept of critical thinking. I've never heard anyone (chinese college students) talking about way of thinking.
14:41
so essentially the world is becoming more chinese
14:41
HUH
Avatar
A civilization invents generative ai, everyone becomes morons, the civilization completely dies off
Avatar
Avatar
TsPiggy
get this. chinese does not even have the concept of critical thinking. I've never heard anyone (chinese college students) talking about way of thinking.
The sort of education system in China/Turkey/Korea/India is really not very conducive to developing critical thinking skills
Avatar
China/Turkey/Korea/India one of these is not like the others
14:43
i live off pattern recognition instead of critical thinking for 30 years. i think i'm doing just fine.
14:44
wait am I autistic
Avatar
Avatar
TsPiggy
China/Turkey/Korea/India one of these is not like the others
We were all neighbours thousands of years ago
Avatar
Avatar
Learath2
We were all neighbours thousands of years ago
i'm really not any good at history
14:46
holy shit it's the same thing. never connected the dot
Avatar
About 1500 years ago, early Turks lived where the Mongols now live
Avatar
ye just googled that and it makes sense now
Avatar
We used to roam the steppe and raid Chinese villages
14:49
huhh
14:52
does plasma change wallpaper every minor version?
14:52
updated system reboot and now the wallpaper changed
Avatar
@zhn what's the difference between these
Avatar
Avatar
pilonpl
yeah but i guess i don't need the DynamicArray struct on the heap, just the void* data portion of it
actually there is 0 reason to put it on the stack anyways
17:02
so like idk
17:02
i might change it to my usual approach
Avatar
Avatar
TsPiggy
@zhn what's the difference between these
♂S1mple♂ 2025-02-16 17:15
russian language for belarus, kyrgizstan, russia respectively? (edited)
17:15
0 idea what is the difference
17:15
logically there shouldn't be
Avatar
Avatar
pilonpl
actually there is 0 reason to put it on the stack anyways
I guess a good rule of thumb would be to use heap allocation for structs which require an allocation anyways because of their member and use an init function otherwise
Avatar
the absolute state of this stash tab
Avatar
Avatar
♂S1mple♂
russian language for belarus, kyrgizstan, russia respectively? (edited)
thx
Avatar
Avatar
Learath2
the absolute state of this stash tab
wtf is this??
Avatar
looks like diablo 2 chest, ut most likely is poe 2
18:50
runes are defienietly used for enchantement (never played that game )
18:51
quite possible if fit together in certain order they make sentence and enhance gear even more than what they say on description
18:51
rest seems to be rings, gems, and upgrade materials
Avatar
almost, the rings are equippable, the stuff on the right are trinkets, they give you a certain boost (edited)
18:52
the bottom left ones are affixes (edited)
Avatar
it's poe2, and it's my very messy rings and amulets chest, most of which are kinda useless ngl
Avatar
the gems in the middle are used in your skill tree
Avatar
low item level, normal rings, idk why I like hoarding this stuff
Avatar
Avatar
meloƞ
the gems in the middle are used in your skill tree
but does one enjoy using them? or its more of the "i have to have em"
Avatar
I have 3 tabs full of gear that is probably completely useless that I can't bring myself to throw out 😄
Avatar
they're used in crafting
18:52
they're neat
18:52
tho the trinkets are useless
18:52
learath clear up
18:52
kekw
Avatar
Avatar
meloƞ
tho the trinkets are useless
probably wont happen in poe... but reminds me of certain mmo i played, where certain trash items suddenly were changed in a single update, as a temporary buff on weapons
18:53
and their price went from not even picking up to... huge
Avatar
this tab is full of gear for other classes that I thought might be useful if I decide to play them
Avatar
this looks like you're still missing an exotik tab (edited)
Avatar
This one is full of my old gear that I can't bring myself to throw out because I used so much currency along the way 😄
KEKW 1
Avatar
Avatar
meloƞ
this looks like you're still missing an exotik tab (edited)
What is an exotik tab?
Avatar
Avatar
Learath2
This one is full of my old gear that I can't bring myself to throw out because I used so much currency along the way 😄
cant U sell back to players?
Avatar
Avatar
Overlord
cant U sell back to players?
I could but this sort of early game gear is worthless in the market
Avatar
you have 1 slot for every exotic there is in the game
Avatar
Oh I have that one already
Avatar
pretty nice if you have a handful and want to clear up
18:55
oh i thought that was an exotic hand i saw
Avatar
Avatar
meloƞ
oh i thought that was an exotic hand i saw
Avatar
Avatar
Learath2
Click to see attachment 🖼️
thats.. not a lot :o
Avatar
Avatar
Learath2
I could but this sort of early game gear is worthless in the market
find friend, or internet friend, coax them into playing poe, drop it on them, problem solved, friendship advanced
Avatar
This is my actually useful gear tab that I might want to switch to after I decide wtf I'm doing with this character
Avatar
Avatar
meloƞ
thats.. not a lot :o
I have been extremely unlucky for uniques until very very recently
Avatar
Avatar
Learath2
I have been extremely unlucky for uniques until very very recently
feelsbadman
Avatar
I got like only 1 from act 1 normal to act 3 normal. Then I got like 2 from act 1 hard to act 2 hard.
18:57
Then in just the last 5 hours of gameplay I got 5 uniques, a random divine and 3 exalts just going through act 3 hard 😄
Avatar
what the hell
19:03
3 tiers?
Avatar
It'll be free after early access btw
Avatar
free as in free to play?
Avatar
Aye
19:05
and the different tiers there give you different cosmetics and some store currency to buy more cosmetics or stash tabs
Avatar
wow
19:09
raspberry pi 5 has a 16 gb ram version (edited)
19:10
i bought mine like 3 months ago and it's already outdated
Avatar
I'm having extreme trouble picking what food to order
Avatar
Avatar
Learath2
I'm having extreme trouble picking what food to order
when was the last time you had something fatty
Avatar
Avatar
meloƞ
when was the last time you had something fatty
4 days ago
19:12
I think I'll get a burger or kfc, but can't decide which
Avatar
burger sounds good - kfc is expensive espacially if you want something next to your chicken
19:13
back then i could never JUST have a burger or JUST have chicken, i always needed something on the side like a salad or smth
Avatar
The Impact of Generative AI on Critical Thinking: Self-Reported Reductions in Cognitive Effort and Confidence Effects From a Survey of Knowledge Workers
https://www.microsoft.com/en-us/research/uploads/prod/2025/01/lee_2025_ai_critical_thinking_survey.pdf
(edited)
Avatar
Avatar
Chairn
The Impact of Generative AI on Critical Thinking: Self-Reported Reductions in Cognitive Effort and Confidence Effects From a Survey of Knowledge Workers
https://www.microsoft.com/en-us/research/uploads/prod/2025/01/lee_2025_ai_critical_thinking_survey.pdf
(edited)
I posted this a couple hours ago 😄
Avatar
well, maybe i also run on AI
Avatar
Avatar
meloƞ
burger sounds good - kfc is expensive espacially if you want something next to your chicken
It looks like it's about the same price
19:15
but I'll just get a burger anyway, I don't want to think anymore and I'll starve
kek 1
Avatar
i got rice with some omelets and lardons
19:16
i'll probably add some peas and green beans
19:16
then ofc, im french, some cheese
Avatar
My sink is leaking, so I can't wash any dishes, so I can't cook anything
Avatar
fix it
19:18
using magic
Avatar
This sink outage is really taking a toll on my wallet
19:19
it just had to happen on a friday
Avatar
can you also fix my toilet flush btw ?
19:19
and my bathroom sink as well
Avatar
I'm handy with that kind of thing, but sadly the sink has a broken o-ring. There is not really much I can do about it pepeW
19:21
Can't even go buy a new o-ring because it's weekend
Avatar
cast your own?
19:24
smh
Avatar
Avatar
pilonpl
I guess a good rule of thumb would be to use heap allocation for structs which require an allocation anyways because of their member and use an init function otherwise
omg, there is an issue tho with realloc
19:32
i guess DynamicArray** solves that issue
19:35
or i guess just two mallocs
Avatar
Open-source cola is any cola soft drink produced according to a published and shareable recipe. Unlike the secretive Coca-Cola formula, the recipes are openly published and their re-use is encouraged. The texts of OpenCola and Cube-Cola recipes are published under the GNU General Public License (GPL).
20:14
no matter if its russian fake or original, taste is the same unlike fake cocacola we have
20:15
i also really like sour
20:15
i eat full lemon for breakfest
Avatar
apelsin (edited)
Avatar
Viktor Antinov, art director of Half-Life 2, has sadly passed away at age 52.
20:58
sad
Exported 567 message(s)
Timezone: UTC+0