#đȘ -progaming
1 messages · Page 100 of 1
i get the same result with !=
well whats Transferable
it seems like it's a container of some sort
probably over ffi or whatever
you should compare the underlying content

too silent
comparing undlerlying content doesn't seem to work
i think i will just make some native code for what i need
it says you posted it
stack exchange reminding me of old stuff
this is the best thing i have ever posted
reminds me of when i searched up what an auto var is in C and got this post
B is a funny language
does register exist in c++
./run ```cpp
int main() {
register int a = 42;
return a;
}
@shrewd canopy I received cpp(10.2.0) compile errors
file0.code.cpp: In function 'int main()':
file0.code.cpp:2:16: warning: ISO C++17 does not allow 'register' storage class specifier [-Wregister]
2 | register int a = 42;
| ^
sad
the only keyword from C that doesn't exist in C++ is restrict iirc
C++, the C superset that isn't
when i think of things c has but c++ doesn't i think of well defined union type punning and the ability to use & with an rvalue
i imagine the latter is limited but i remember being able to do &(SDL_RECT) {0, 0, 10, 10}
maybe it's a weird compiler extension idk
youâre still restricted in C
you canât do &1 to automatically put a 1 on the stack somewhere and give you a pointer to it
thats not really useful anyway
dynamic stack allocation 
itâs been pretty useful in elle code
when would you use an int pointer other than output param
it is actually
an input output param that you don't actually want to read
use std/prelude;
fn direction(i32 *other) -> bool {
return !other ? direction(&0) : &0 > other;
}
fn main() {
io::printf(
"The stack is growing {}wards for your architecture.",
direction(nil) ? "up" : "down"
);
}
well no, you can swap the int for anything
struct intt { int value; }
uv_mango.le: Lines 44-49
rl::set_shader_value(
shader,
rl::get_shader_location(shader, "time"),
&#cast(f32, rl::get_time()),
ShaderUniformDataType::SHADER_UNIFORM_FLOAT
);
but the ergonomics of being able to take the address of any rval
is nice
oh and of course c has vlas
gc.le: Line 101
self.__internal_mark_region(#cast(void **, &0), #env.stack_top);
in c++ you need to use alloca
vro.
vlas in what sense
being able to do int foo[bar] with an arbitrary rval in bar?
with arbritary expression
I don't think alloca is allowed in C++
well yeah an rvalue would be an expr
wdym it's a non standard thing anything doesn't this depend on implementation
does c++ not let you do this???
alloca would mess up destructors
nope
wow
std::span
whats a span
^
what would it do
static arrays canât exactly grow in size so a slice/span works well
that sounds fun
can't unwind stack if you don't know the stack size
i know the stack size
seems to "work" with ints
huh
(not really)
idk if this happens in c too
but surely alloca would increase sp so how would it cause weirdness
won't i be a register anyway
maybe i should just add register
@signal oak create doom in c++ templates
bwah
Does int* foo = new int[bar]; not work for that
rust brainrot
irrelevent languages
yes
god damn i'm a genius...
ram is your bedroom floor heap is the random clothes scattered around stack is the stacked books
@winged mantle will clean up their room
this is not a self-referential your
i swear is there no good clipboard library for linux
how tf do i get notified without making like 10 specific implementions for each DE
does wayland make it hardfer
execvp("wl-copy", "--watch")
Donât care about stack or heap or whatever im shitting in your ram and causing a pc crash
yes and no
if wayland wasn't a thing, i would just use c/c++ for this
there is an XDG Desktop portal for this
but kde doesnt support it
it has it's own dbus interface thing for it
Wish APIs were actually unified per platform
Wayland is supposed to do that
Unfortunately they forgot to ask both users and developers for feedback
how can i edit this tooltip?
I frankly do not understand how online video games coded in C++ are ever safe to run at all.
QRT: vxunderground
Gamers are going ballisticCall of Duty WWII, available on Xbox PC Game Pass, contains an unpatched RCE exploit
Someone is trolling gamers with Notepad pop ups, PC shutdowns, and gay pornography https://t.co/FLNzRbLt1s
this is massive skill issue
rust solves only memory safety issues, not security issues
well it depends
âsecurity issuesâ could happen due to a wide range of bugs
it just happens that rust can deal with most if not all of the memory related problems that could lead to any potential security issues
while it does not stop security issues as a whole, I.E. logic bugs can still occur. It does solve the most common ones
a majority of security related issues are usually memory related whether it's uaf, double free, stack smashing or a buffer overflow
heartbleed is a good example, and iirc the 2019 chrome zeroday was related to heap corruption that allowed for ace
swiftonsecurity đđ
tssss
which one would you use
pycord
or discord.py
im using discord.py rn but i was just curious
pycord is ass
log4j
No swearing in this christian minecraft server
@valid jetty me when i dont want to make a parser
I donât like the fact that here and golang this isnât a explicit type
70% if you believe some companies.
Some of the biggest attacks in history have nothing to do with that tho. Just incorrect permissions or logic exploits.
Or social engineering
Yop
Does not matter how many array slices you bounds check if I can get a intern to plug in this one simple usb stick
L rust
you can exlicitly type it if you want
i32 x = 42;
You can in go as well. I donât like the implicit :=
How do you handle variable shadowing?
exactly as youâd expect
if I for example have
Var someString string
if someString, err := someFunc(); err != nil {
return err
}
fmt.PrintLn(someString)
In go someString is never written to and it pisses me off
in elle that doesnât happen
if you use := in a tuple destructure itâll shadow the previous variables
Oh you can redefine the type of the var itself within the same scope? Thats⊠that would be a headache to actually use
well, yes because as far as the compiler is concerned the previous variable no longer exists
it just resolves to the last defined x
iâve found a single good use for it
What use?
fn main() {
server := TcpServer::bind(port := 8080);
while server.is_err_and(fn(err) err == Errno::EADDRINUSE) {
server = TcpServer::bind(port += 1);
}
server := server.unwrap();
defer server.close().unwrap();
$printf("Server is listening on port {}", port);
connection := server.accept().unwrap();
defer connection.close().unwrap();
buf := Array::bytes(BUF_SIZE);
while (_, received := connection.read(buf)) && received != 0 {
$printf("Received {} bytes: {}", received, buf.join("").replace("\n", ""));
connection.write(buf).expect("Failed to send response");
}
}
the server := server.unwrap();
Oh yeah I guess it could be useful for that instead of polluting the name space
yeah
itâs fine because thereâs an lsp
you get hover diagnostics
(and itâs strongly statically typed)
I think code should be readable without a LSP
if you try to use the .close method and it hasnât been unwrapped youâll get an error at compile time
i mean imo itâs still readable
i mean nothing is stopping you from giving the unwrapped or wrapped version different names
you could have maybeServer -> server or server -> serverUnwrapped
but generally youâre allowed to shadow like this because why not
youâre never gonna use the result ever again, so why not overwrite it (as far as the compiler is concerned)
also, you can only redefine the varâs type if youâre shadowing the previous one
you canât do
x := 1;
x = âhiâ;
Yeah that makes perfect sense
maybe i can make a pedantic compilation flag which disallows shadowing? but iâve seen very very rare cases where it actually screws you up
A warning, but not an error?
Pedantic to mean just means all warnings becomes errors
oh true i could just make it a warning
i need to stop thinking like andrew kelly itâs not good for me
one big differentiator is that i fucking hate immutability
it just becomes annoying at a point
i have like 100 pub keywords in some of my rust files because i have to make every single field public (which is a different problem)
but yeah, variables are mutable, all pointers are mutable
and i will die on that hill
You miss out on compiler optimizations and safe assertions
i mean i guess thatâs true
but until i switch to a non-qbe backend the optimizations i can do are already very limited
can do that in rust as well afaik
you can yea
Ex, if I multiply by a global constant that isnât Inlineable and mutable then the cpu has to deference it first.
Which actually can SOMETIMES be faster in specific scenarios or ISA
I donât like it in it either
in rust mutable constants are unsafe lol
because thread safety
i guess rust compiler is smart enough to fail on some unpredictable ones iunno
and anyway âmutable constantâ is a contradiction
i think you mean mutable global static
I meant to use constant in quotes not literally
oh
Static means something else depending on the context
well yeah but in a global context it means the value is constexpr and, if mutable, is put into the uninitialized data section .bss
thatâs what you mean 99% of the time when you say static variable
That makes me think of something Iâm working onâŠ.
I have mutable globals but I hate it
i have tried to make global mutable variables usable but itâs hard
global!(POINTER_ID: &str = "__ptr__", get_POINTER_ID);
#[macro_export]
macro_rules! global {
($name:ident : $type:ty = $value:expr, $getter:ident) => {
pub static mut $name: Option<$type> = Some($value);
macro_rules! $getter {
() => {
unsafe { $name.unwrap() }
};
}
#[allow(unused)]
pub(crate) use $getter;
};
}
``` because rust
Yeah that sucks.
i donât even need this bearocracy because the compiler is single threaded
I assume rust is smart enough to see that there is an unsafe reference to a global constant to then not inline said constant?
Else you get undefined behavior
Oh wait, itâs defined as mutable
So ofc it wouldnât inline
Itâs not a constant cast to mutable
Why would it even be unsafe tho as long as itâs wrapped within a mutexâŠ.. something something pointers
@hoary sluice is there a way to write this more elegantly with less allocations
fn Array::merge_sort<T>(T[] self) {
if self.len() < 2 { return self; }
return self.iter().map(fn(x) [x]).collect().merge()[0];
}
fn Array::merge<T>(T[][] self) -> T[][] {
if self.len() < 2 {
return self;
} else if self.len() == 2 {
res := [T;];
xs, ys := self;
i := j := 0;
while i < xs.len() && j < ys.len() {
if xs[i] < ys[j] {
res.push(xs[i]);
i += 1;
} else {
res.push(ys[j]);
j += 1;
}
}
// one of these will be empty :)
res.extend(xs.slice(i, -1));
res.extend(ys.slice(j, -1));
return [res];
} else {
res := self;
while res.len() > 1 {
// you cant escape this while-loop with fold :(
res = res.chunks(2).map(fn(x) x.merge()[0]).collect();
}
return res;
}
}
i can do a swap buffer but then that no longer has the super elegant res.chunks(2).map(fn(x) x.merge()[0])
and the actual merging logic for when the len is 2 is kinda mehhh for readability
i had a version before which was more elegant but it was O(n^2logn) because it popped from the lists from the front which shifted everything back down
i guess the most elegant way to write the merging logic would be to use a deque but i dont have that in elle
i might just write one specifically for this
ive wanted one for a while but if i write it i need to do it right
yo do packages like pynput and pyatuogui support flatpak apps?
@fleet cedar is a lot smarter than me
of course
great that means i have a bigger issue i needa fix
real
i have 2.37.0.windows.1 so 
is it over now?
wdym over
Apple ships git 2.39 đ
it shall stay this way
~>git -v
git version 2.39.1.windows.1
That's better.
it has a command for apple
it says all versions <= 2.50.0 are vulnerable
yeah
yop
it's in 25.05 staging and been in master for a day
still hasn't hit unstable
đ
default.nix: Line 63
version = "2.49.0";
@royal nymph https://www.youtube.com/watch?v=npUDDjQ9J_w
Async/await has been a game-changer for JavaScript, revolutionizing the way we handle asynchronous operations and making our code more readable and maintainable. However, as powerful as it is, async/await has its limitations, especially when it comes to type safety and error handling in TypeScript. In this video, I explore an alternative approac...
this is kind of awesome
this sucks who taught the aibros yield
pls watch the full video this is actually pretty cool
you can replace await with yield but it creates the same problem as async đ
You posted effect here before and I didnât like it then
thats not the problem it solves
using yield, you can bubble up tagged errors
which you cant do with await
but there is more interesting stuff
@grok summarise this video
this is awful, this is just old nodejs style callbacks, but wrapping promises
and old node users know how insane of a pain that is
fun fact, python is used to have coroutines implemented with yield and yield from
it is not like old nodejs callbacks
it is just re-wrapping them
its half an hour long no one is watching
which is awful
it is not doing that đ
lc.gpt tldr
The video introduces "Effect" as an alternative to async/await in TypeScript, addressing issues of unpredictability and error handling. Key points include:
- Issues with async/await: It's unpredictable, especially with success and error channels, and often requires try/catch blocks for unknown error types.
- "Effect" Features:
- Explicit Error Modeling: Allows tagging different error types with full type safety.
- Defined Channels: Clearly defines success, error channels, and dependencies.
- Structured Error Handling: Uses utilities like
catchTagsfor specific error types. - Data Parsing: Includes @effect/schema for runtime validation and parsing.
- Enforcing Return Types: Uses
makeEffectto type success channels, preventing type mismatches. - Rich Utilities: Offers retries, filtering, and an HTTP client for error-managed, schema-based requests.
The speaker recommends "Effect" for more predictable, type-safe asynchronous code management.
sir, it legit is, you have await wrapped into a generator callback on each step
this is just nodejs callbacks, just more complex
what even is the point of this
the difference is that if something can fail in a yield, the error is propagated to the generator's type signature so you can catch it later
this is worse than async/await
so you get x10 the boilerplate, x0.1 the readability and pure pain
type safety
TLDR typescript doesnt implement @throws
and with this you can have type safe errors
yeah
errors are a skill issue
just use a discriminated union if errors matter that much
i 100% agree that lack of error support is a BIG problem in TS
it has much more than just type safe errors however
can't really be solved tho
it can
JSDoc solved it decades ago
simply no1 implemented the spec
it has requirements for dependency injection, a ton of utility functions, etc..
if my code throws an error its a user problem
i should really look into DI sometime
true
never really gave it much thought
DI?
dependency injection
i arrived at a simple solution for errors in TS tho, if its a promise, then it throws an error, always.
I love DI
sir... thats step 1 of programming doe
i cant imagine anything without DI
guh
what even is it
i've heard of it before, but never used it
it's a nonsense term tbh
basically, instead of a class creating it's own dependencies (such as the objects it needs to work) such are provided from the outside (a different class)
wouldn't that just mean passing a bunch of poilerplate parameters around
basically
constructor hell
â€ïž
horror
for di
@signal oak what is koin
class MySomeThing {
constuctor (myfilestrture: Directory) {
this.myfiles = new myfiles('/base/')
}
something () {
return this.myfiles.entries()
}
}
di framework
The Kotlin Dependency Injection Framework
love the domain
it gets even better they're sponsored by a fuckton of csgo gambling sites
WHY ARE THEY ALL MADE USING KOTLIN
INSANE
you have some abstract structure, and something that consumes said structure, then anything that implements said structure can be used, and the consuming class doesnt really care how it implements it, all it cares is that it implements it
because kotlin is superior
I'm writing my compiler for x86 -> jvm in kotlin
writing cursed java rn
public class ClipboardWatcher implements AutoCloseable {
@SuppressWarnings("unused")
private final ClipboardChangedEvent onChangeCallback;
public ClipboardWatcher(ClipboardChangedEvent onChange) {
this.onChangeCallback = onChange;
this.setupListener();
Thread t = new Thread(() -> {
});
t.setDaemon(true);
t.start();
}
public native void setupListener();
public native void cleanupListener();
@Override
public void close() {
try {
this.cleanupListener();
} catch (Throwable e) {
e.printStackTrace();
}
}
/**
* some data for native, probably a pointer.
* <p>
* if you change this, you probably will segfault
*/
@SuppressWarnings("unused")
private long nativeData = 0;
}
so pretty much any W3C defined spec, that is then implemented anywhere, you don't care HOW File works in JS, all you care about is it works
what are u working on even
need to be notified when clipboard changes
for mobile?
im guessing because
no
oh
this is desktop jvm
why is it in java then
eaiser to work with JNI imo
(cba to learn jni for kotlin)
I love jni i create 1000 dummy dll's for my drm
damn, discord already sold my data, that was fucking QUICK
my bad
is that the same guy that made the last video
jesus
JNI in kotlin isn't really any different to how you'd use JNI from java
its just external func nativeshit(): string rather then public native string nativeshit();
unless that isn't what u mean
why don't u just write it to work outside the jvm đ
wdym
like
my app is in kotlin
oh
i need c/c++ code to get when the clipboard changes
you can't do it in java, even with polling (in any sane manner)
what is kotlin used for then? the gui etc
yeah
I see
I've been using skia a lot recently for rendering stuff myself
and it's been awesome
neat
mostly via tiny-skia in rust
idk i love jni
ive done so much with jni
i could probablyh talk about jni all day
oh interesting
(no js tho)
yeah
iirc aren't typealiases a compile time thing?
right, dont do shit while updating drivers
when i update my drivers i actually start probing the cpu mid update â€ïž
fixes all my issues ever
What does probing mean
running some random benchmarks (and viruses)
i got a new keyboard!
congrats!
vscode release notes be like:
- ai
- ai
- more ai
Tf is MCP anyway
Also aren't half of vscode updates just them adding special integrations for copilot chat?
I hate this sm
That would be a much better feature tbh 
Minecraft patcher?
does anyone know how i can edit this tooltip?
wow this is so much slower than quicksort lol
jni is fun
goes to show that time complexity is not necessarily linked to speed i guess
merge sort on a 10k array with random numbers from 0-10k takes 4m 23s, quick sort takes 29s on the same array
and there are both O(nlogn) :3
wow actually
the quick sort is almost instant đ
the actual formatting of the array into a string takes 30s
yeah wtf
why is the quick sort so much faster than merge sort even though they have the same time complexity
fn Array::sort<T>(T[] self) {
if self.is_empty() || self.len() <= 1 {
return self;
}
__internal_qsort(self.elements, 0, self.len() - 1);
return self;
}
!pub fn __internal_qsort<T>(T *array, i64 low, i64 high) {
if low >= high {
return;
}
T pivot = array[high];
i64 i = low;
for i64 j = low; j < high; j += 1 {
if array[j] < pivot {
T temp = array[i];
array[i] = array[j];
array[j] = temp;
i += 1;
}
}
T temp = array[i];
array[i] = array[high];
array[high] = temp;
__internal_qsort(array, low, i - 1);
__internal_qsort(array, i + 1, high);
}
đ
JNI seems relatively simple yet i feel like i will go insane with it
there's quite a bit of footguns that you have to avoid
i'm already using c++ 
why are you using jni
i need to be notified when the system clipboard changes
from java?
why dont you use jna or ffi đ
something like this
but only if you use new java version
what the hell is this https://dev.java/learn/ffm/native/
why so much bloat to call a C function
yeah
i mean, tbf im more comfortable with using jni-like syntax too
to make it "safer' or something
it seems a lot more complicated then it needs to be
its just that jni will soon become deprecatzed feature in new versions of java
jni is so much more simple
I don't remember it being deprecated
will soon
it's just turned off by default for security
i doubt that
i feel like the native keyword got so much potential, when i wrote my own jvm, i added this annotation which allowed to invoke the method as-is without having to do package shit, that was pretty cool
(yes its gpt generated lmao)
i remember reading this
didn't look too deep into it tho
Since Android 12, a call to a @CriticalNative native method from a compiled managed method is almost as cheap as a non-inline call in C/C++ as long as all arguments fit into registers
neat
i wonder how much heavy lifting almost is doing there
omg @hoary sluice i can make namespaces like zig
look at this đ
use std/prelude;
struct Std @nofmt {
@unused io *io,
@unused libc *libc
}
struct Prelude @nofmt {
@unused Std std
}
const prelude = Prelude{};
const std = prelude.std;
fn main() {
prelude.std.io.println("hello, world!");
std.io.printf("wtf {}", 39);
}
this just keeps getting worse and worse
elle more like js
yes
no
I play games, what games you like?
got me
real
is it becuase of miku update
Get this Roblox garbage out of my precious programming channel!!!!!!!!!
âŒïžâŒïžâŒïžâŒïžâŒïž
yesh
shush
Get this Roblox garbage out of my precious programming channel!!!!!!!!! Get this Roblox garbage out of my precious programming channel!!!!!!!!! Get this Roblox garbage out of my precious programming channel!!!!!!!!! Get this Roblox garbage out of my precious programming channel!!!!!!!!! Get this Roblox garbage out of my precious programming channel!!!!!!!!! Get this Roblox garbage out of my precious programming channel!!!!!!!!!
wow spammer
ban
new pasta just dropped
ufffff
think its really funny how every modern language now uses "let" for variable declaration
except for zig
zig uses const and var
thats why nobody uses zig
you are of the same opinion on lua in general too?
no
i just dont want to open this channel and see "tycoon" i want to open this channel and see programming nerds
oh yes, r*blox uses its own strong typed fork of lua
what if we rename this channel to progaying next june
in my goal of not having any deps i have now dug into win32 api and c interop and made my own tracing macros
we stay winning tho!!!
I've done so much with JNI
I've been writing something to help with reverse engineering stuff related to JNI recently in Rust
Mostly to fuck with https://jnic.dev
(I also made my own thing similar to this that used JNI in Rust, basically JVM -> Rust transpiler for mostly making stuff harder to analyse)
Obfuscation 
obf*sc*t*on
I LOVE OBFUSCATION
WHAT THE FUCK IS A STABLE CFG
WHY IS THERE 5000 BRANCHES
WHAT IS GOING ON âŒïž
It's great
Idk I like obfuscation not writing it but I like dealing with it
It's fun to mess around with
since it's usually all done via dynamic analysis if it's x86 noting it's a lot harder to-do it via symbex/similar noting cryptography is used in a majority of string obfuscation & similar
glad the library i am reverse engineering aint obfuscated at all
I LOVE REVERSE ENGINEERING RANDOM OBFUSCATED MC CHEATS
what is even going on âŒïž
OwOwOw
meowemow meow
imhackerlolquestionmark
owowowo.py is so good
oh yeah
a lot of people seem to not know about function hooking because a majority of the time their shitty antidebug is usually touchable via just hooking ntqsi lol
@valid jetty @placid cape advantage 360 next??
Have you seen movfuscator? https://github.com/xoreaxeaxeax/movfuscator
like years ago yea lol
and what phone do you have? yes.
this isn't the most interesting this person has done
he figured out a Ring -2 privilege escalation exploit
yes thats the whole point
ummm technically he just used someone else's paper

wait what
bottom of readme
@ChristianSelig @pwign shhh nobody has to know
Image(_internalSystemName: "recap")
Image(_internalSystemName: "hand.side.pinch")
there's also a video about it on youtube
Yeah, I assume thatâs where most people have heard of it from https://youtu.be/HlUe0TUHOIc
Your precious 0-day? That meticulously crafted exploit? The perfect foothold? At some point, they'll be captured, dissected, and put on display. Reverse engineers. When they begin snooping through your hard work, it pays to have planned out your defense ahead of time. You can take the traditional defensive route - encryption, obfuscation, anti-d...
Realizing it was 9 years ago đ
i've seen that one before, but it's not the one i'm thinking of
omg
clean ur url
nop
Eww
unreadable
does converting math expressions into postfix make sense in a language? i found it easier than making an ast
Sure, a lot of bytecodes do that
who that 
wtf is bro doing
I'm writing an obfuscator for nix
Why does n*x needs an obfuscator
its already obfuscated
it's already terrible why not make it worse
â€ïž
yanderedev's successor
lmao
this is like as bad as yanderesim
what is bro doing
them showing off private apis is crazy
makes pretty good videos trying out different programming/game dev concepts
Let's try to turn some dot products into a 3D world!
Support my work (and get early access to new videos and projects)
https://www.patreon.com/SebastianLague
Source code:
https://github.com/SebLague/Software-Rasterizer
Credits:
Music: https://raw.githubusercontent.com/SebLague/Misc-Project-Info/refs/heads/main/Coding-Adventures/Rasterizer.txt...
we need this but built in to compose
its 2025 and theres still no conclusive way to figure out recompositions
just send me the nix and have me us it in my dotfiles
same thing
im making this worse btw
I want to find a way to get around nix repl and I have a few ideas
although they're all complex
impossible
the worst possible way to do i18n on switch for sure
youtube has been pushing WAYYY too much logical redstone so i tried my hands at it.... 8 bit binary addition without any help... took me a couple hours đ (only looked up the real life circuit for a full binary adder)
Bro just learned game maker give him some time
HAI MAC OS
đ
this is literally what made me write one
he constantly goes around saying he has 20 years of experience at blizzard and amazon games and also said he hacked into nuclear power plants for the government
its crazy
Link to Stop Killing Games, sign it if you're in the EU!
https://www.stopkillinggames.com/
This is part 1 of a larger series I'm doing on PirateSoftware, where I'll be judging his job history, industry claims, development hell, DRM solutions, and game code. In this part 1 I'm just going through his job history + industry claims, and the develop...
the glorious giant ass commit with the "add a ton of new stuff" title
who is @vale geode
đ
i fear i do that
sometimes i commit but not push when i add something but i usually forget to
yea thats what happened here đ
is there a known alternative to old TextElement? the one that aside from being a component also had Sizes and Colors nested objects
using the win32 api always makes me want to explode
I am implementing IR for Nix
java dev was here...
https://vxtwitter.com/yutongwu111140/status/1943615182061642058
At least its not javascript tho
all of this is valid javascript
i think its c++ because the tweet author primarily does c++
not possible
new creates pointer which uses ->
you owe me. i got muted for that
i just got u in my tl 
yep follow me
ok bet
have you considered just using renderdoc
shit don't work in a compatibility context
how so
it ONLY works in a MODERN CORE CONTEXT
and if i were in a modern context
i would be using bindless textures
BUT GUESS WHAT !!
IT CRASHES WHEN YOU DO THAT TOO
rip
Shit fucking sucks
Only works if you follow their special rules
apitrace is goated thoe
meanwhile I gotta learn aarch64 binary because keystone is gpl 
bro why are you even on 1.7.10 smh nobody plays that shit anymore
1.7.10 is peak
i will not take this hate
1.7.10 is the version i have the most hours on i think
maybe a close second behind 1.8
Been working on a modpack for 1.7.10 for years now
thats the version i grew up on that has all the mods
No point moving tbh
ok but in the big 25
you still have big modpacks that are on 1.7.10
if you search for recommended modpacks rn people will recommend you modpacks on 1.7.10
just this week i was recommended ftb infinity evolved which is in fact on 1.7.10
im gonna use log4shell on you
who is that
u cant i exclusively play on minecraft bedrock now
there's nothing important in my downloads folder
i do that often
next delete app data
nop
jdwp is so dumb
I remember a minecraft cheat using it
to make it seem like you didn't have to download the client lol
????
idk it's implementation isn't amazing and if I'm being honest I've only seen it be used maliciously or in other dumb ways
vro
it's literally like
the thing that Java debuggers use
I know
what's wrong with the implementation then?
99% of the time this is just used for generic java debugging, then the 0.nothing% for cheat clients and the like
I mean, I mostly just dislike how it's extremely coupled to hotspot because it means it's implementation is weirder on other VMs (I've personally had issues with such), same with the fact that by default it's security model sucks
Also, iirc JDWP still has synchronization issues too
I only test against Temurin
Same with the protocol being ass
protocol works in the background, i only do the check to see if the intellij debugger is connected
it's been a while so I'm hoping they're fixed but I had issues with GraalVM/OpenJ9
I mean, for most people what I said wouldn't matter anyways since they're just debugging like the MC client or smth else locally lol, but idk I just think for how long it's existed it could've definitely been improved
idk graalvm is pretty cool and provides a lot of stuff most other VMs don't
Cool in concept, but in practice it's compat hell
And up until pretty recently, you needed the enterprise version to get any perf gains
Last I measured it, didn't provide tangible gains for me
At this point if I need more performance I can just write Zig and load the native, be that via JNI or Panama
I mean, the Graal compiler is still in CE, same with IGV which is pretty nice, and in terms of diagnostic data & similar Graal does give the most I've seen with any VM, I think the issue with Graal is that a lot people exaggerate it's performance impact when it really isn't that big
What diagnostic data in particular?
Mostly related to the Graal compiler
I know they give a lot of information related to its IR
fair enough
I do a lot of stuff regarding optimisation and having more data is always nicer, a lot of different VMs don't provide such so Graal doing so is great
I have my JProfiler licence and that gets me plenty far
I just write whatever I need using jvmti 99% of the time nowadays
I don't rlly use jprofiler as much as I used to but I still think it's nice to have
At the end of the day most of my code ends up being GPU limited anyway
rendering stuff?
Yop
Few months back wrote a mod to add Tracy support with GPU profiling for 1.7.10
I do a lot related to transpilation/re with the JVM rlly
I've been getting into rendering stuff a bit
not in the JVM though I've been working on my own compositor for Wayland
self-destruction mechanism
@nimble bone
I am working on a transpiler for Nix
I kinda wanna dm them like yo I'll have a look and make it work for 5k 
The fuck you mean 50 to 60 thousand lines
its ai so 59k lines of comments
Oh right
i think elle can have japanese fields in structs đđ
i havenât tested it but the idea just popped up in my head and i think itâll work
60k lines of slop
does it also support unicode escape sequences like js does? 
Horrible
TIL javascript supports this 
WHY
rust documentation is so deep..
ill just die on that hill
(not only japanese)
@hoary sluice you can write elle in russian
how do you feel about that
fn is_cute(VencordMember hiii) {
match hiii {
VencordMember::PaiPaiPaiPaiPai
| VencordMember::Llsc12
| VencordMember::Vendicated => true
VencordMember::Bendicated => false
}
}
this is an exhaustive match, there are only 4 vencord members overall
you, llsc, vee, and evil vee
how do you "accidentally" add unicode support
who is evil vee
well, it turns out rust's char::is_alphabetic includes unicode alphabets
and then i just have to properly encode the symbols in the qbe file where necessary and it just works
lol
ok i've been programming for nearly 10 years
i just discovered how casting integers to a smaller type works...
i don't think i've ever done it in a case where it changes the value
as in, bit masking?
if you cast a u64 to a u32 you get the lower 32 bits (or x & 1 << 32)
I scored 10/28 on https://jsdate.wtf and all I got was this lousy text to share on social media.
i always assumed high level languages would be more intuitive and doing e.g. (uint8) 256 would yield 255 đ idk why
that would have to compicate the machine code for all casts to smaller types

i was planning to implement a programming lang for fun
and if i didn't realise this i would make it work like that
well
you wouldnt because the intermediate representation would do it for you
but yes
wdym
i wouldn't use il
i'd just make an interpreter
without jit
oh wait
ig i could also use language's cast
uint8_t cast_uint16_to_uint8(uint16_t value) {
if (value > 255)
return 255;
return (uint8_t) value;
}

so good
I scored 19/28 on https://jsdate.wtf and all I got was this lousy text to share on social media.
im laughing so hard
we scored 15 with 3 of us doing itXD
alcohol was involved in decision-making
I got 10/28
i think i got lucky
I scored 5/28 on https://jsdate.wtf and all I got was this lousy text to share on social media.
I guess I have too much common sense
I scored 16/28 on https://jsdate.wtf and all I got was this lousy text to share on social media.
I guessed most of the questions đ
I scored 11/28 on https://jsdate.wtf and all I got was this lousy text to share on social media.
i hated dates before and now i hate them more
i have to know what the new Date() implementation looks like
datetime.datetime my beloved
its wrong
u need to append "at" to [-2] of the print function name
that sentence makes 0 sense
Hello, do you know where I can find Vencord configs?
Good that i can speak russian natively
I scored 13/28 on https://jsdate.wtf and all I got was this lousy text to share on social media.
and lastly, australian
How does this work?
No it's just scattered symbols from all over the table
i guess i got lucky that all of them are considered "alphabetic" by the unicode standard
then
omg do i allow emojis
nvm theres no simple way
type before field đ
do you say "this is my dog max" or "this is max (he's a dog)"
thank u
I say "this is Max", that he's a dog can be inferred from the fact that he's a dog
"Max is in a state of existence" sounds funny
Aren't we all
im not
me neither
maybe make an extension
@young flicker is not decodable
idk who would ever want and/or need this but its here i guess
it is actually decent for cross platform
i think i would rather not
you just have to learn dart
i can also tell when an app is flutter just by using it
someone pinged you
@woven mesa
that was 2 hours ago
the channels are also next to eachother
idk then
subconsciously started talking about a programming thing in a programming channel
whats my youtube byundle id
com.llsc12.youtube
@frosty obsidian do u love my software rasteriser
where is 4k hdr raytracing
idk man its a single cpu core
i wrote a spinning cube this is basically the same thing right
:3
how much code is yours
the cube is only this
use std/prelude;
use std/raylib;
enum Screen {
WIDTH = 800,
HEIGHT = 600
}
fn main() {
rl::init_window(Screen::WIDTH, Screen::HEIGHT, "Spinning Cube");
defer rl::close_window();
camera := Camera3D {
position = Vector3::from(4.0),
target = Vector3::zero(),
up = Vector3::xyz(0, 1, 0),
fovy = 45,
projection = CameraProjection::CAMERA_PERSPECTIVE,
};
rl::set_target_fps(60);
while !rl::window_should_close() {
rl::update_camera(#cast(Camera *, &camera), CameraMode::CAMERA_ORBITAL);
rl::begin_drawing();
rl::clear_background(#cast(Color, &0xFF181818));
rl::begin_mode_3d(camera);
rl::draw_cube_v(Vector3::zero(), Vector3::from(2.0), #cast(Color, &0xFFC98FFC));
rl::draw_cube_wires_v(Vector3::zero(), Vector3::from(2.0), #cast(Color, &0xFF1A1A1A));
rl::end_mode_3d();
rl::end_drawing();
}
}
the
the raylib,,
i didnt use raylib for the rendering
wait whatttt
i allocated a block of memory to write my pixel data to
i literally like
oh i see
wrote a 3d renderer

i use raylib for windowing and drawing my framebuffer to a Texture2D to show on screen
and also mouse capture and other inputs
@valid jetty
rate đ„ș
swift,,
can also build to linux
but i set up this proj with xcodeproj instead of standard swift package bc i wanted to have the ability to build into an app bundle
swift doesnt sound like it should be fast but its arc lmao
swift is fast
it runs on iphone sep
also write a kernel or firmware with embedded swift
idk how to use the new swift memory stuff thats for avoiding the unsafe pointer stuff
so i still use unsafe raw mutable pointers

I remember ignoring warning that I was modifying const pointer in c
c const pointers are based because they're not actually const
swift encourages you to avoid using pointers outside a special closure they give you so they can ensure you dont use after free
and also guarantee the lifetime too ofc
i hate languages that treat you like a baby
swift isnt treating you like a baby
bc thats just one of the methods for accessing raw memory
you can also just get the pointer iirc
theres no baby treatment in swift when youâre doing c interop for example
ok fair but thats because a lot of swift depends on objc which depends on C
no i mean like passing pointers and receiving data from c interfaces means you manage memory lifetime manually
objc interop in swift is incredibly decent
c interop is very unshielded
calling c from a binary at runtime is scary

$1.32
true
this guy is so annoying https://x.com/kai_fall/status/1943674349099078110
i dont know rust, but this looks like a bad to do it in rust
they just intentionally make rust look worse than what it actually is
one time they benchmarked the same program in go and rust in⊠debug configuration
also i could be wrong here, but dont you not need clone because an i32 is trivialy copyable
and when was pointed out, was just âwell i just used whatever the default build option isâ

yeah
like none of these type annotations are necessary
yeah
so, show the right way of doing that
thats how it looks like in c
(1..5).map(|x| x * x).sum()
thank you and out
or if you dont wanna cheat like i did
let vec = vec![1, 2, 3, 4, 5];
let mut sum = 0;
for x in vec {
sum += x * x;
}
println!("sum = {sum}");
either way its not as bad as that person is making it out to be
(for the record these examples above are RUST not elle :'))
elle code
lol
??
even i worked this out
rust basics
đ
ok in fairness wat
it's in a vector so it must have a type
why do i need to cast it to the same type it already is
but they didn't use pow in go so its unfair lol
???
somebody explain
no
in rust if you donât specify a type rust makes it an unrepresentable internal type called {integer} which automatically converts to whichever integer you need
so youâre not casting it to the same type, youâre specifying that the generic {integer} is specifically i32
if you hover over a vec without a type specified you can see it says Vec<{integer}>
rust can multiply together 2 {integer}s because it constant folds them anyway
iâm pretty sure that internal type is specifically for constexpr integer literals
it just so happens that when you wanna print the {integer} it defaults to i32 but thatâs not its type
the added benefit of doing it like this is that if you do x * 2, the 2âs {integer} type absorbs to whatever type x is
If the {integer} is un-inferred it defaults to i32, but calling a method on it is an error
Probably mostly because you might be looking for a trait function and that could be dangerous if it guesses wrong
iâm assuming thatâs a semantic backwards compatibility with C
a plain integer literal in C is an int, so you would assume equivalent behavior coming to rust
though rust doesnât have 39L or 420ULL lmao
No, but rust has 98u64
yeah true
no it doesn't
it says Vec<i32>
and it says item is i32
i don't understand... lsp says it's Vec<i32> but the error doesn't go away unless you explicitly type it
let vec: Vec<i32> fixes it
so does having any of the variables inside it explicitly an i32 (somehow the rest implicitly become i32)
integer literals in rust are not i32, they can take the shape/absorb the type around them
^^^
if your vec has an explicit i32 then the other integer literals absorb the i32 and also become i32
the lsp is wrong...
thatâs just your lsp being bad then
RA isn't always accurate with the fine details
you could write vec[1i32, 2, 3, 4, 5] and the error would go away
if you wrote 1u64 the vec would be Vec<u64> because the other int literals also absorb into u64
but it's certainly something that i haven't seen in other languages
it is genius, elle has the same thing albeit it doesnât have an unrepresentable internal type
just if you write an integer literal it infers from context what type it is
think about it, if int literals were always i32 then if you wanted to write a u32 or anything bigger you would get undefined behavior or an error
being able to infer what type it is is a benefit not a downside
but... how does it work



