#đŸȘ…-progaming

1 messages · Page 100 of 1

spark tiger
#

NO

#

im NOT using voice messages

jade stone
#

i get the same result with !=

ornate quiver
#

well whats Transferable
it seems like it's a container of some sort
probably over ffi or whatever

#

you should compare the underlying content

spark tiger
valid jetty
#

i havent

#

i know it exists but i havent played it

placid cape
#

too silent

hoary sluice
#

dalboebsin ba?

jade stone
#

i think i will just make some native code for what i need

winged mantle
#

😭 ??

crude star
#

it says you posted it

winged mantle
#

stack exchange reminding me of old stuff

#

this is the best thing i have ever posted

valid jetty
winged mantle
#

B is a funny language

crude star
#

does register exist in c++

shrewd canopy
#

./run ```cpp
int main() {
register int a = 42;
return a;
}

rugged berryBOT
#

@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;
      |                ^
shrewd canopy
#

sad

fervent torrent
#

đŸ„€

#

i have to work on this too

shrewd canopy
#

the only keyword from C that doesn't exist in C++ is restrict iirc

crude star
#

C++, the C superset that isn't

winged mantle
#

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

crude star
#

C has alloca

#

peak

winged mantle
#

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

valid jetty
#

you can’t do &1 to automatically put a 1 on the stack somewhere and give you a pointer to it

winged mantle
#

thats not really useful anyway

crude star
#

dynamic stack allocation blobcatcozy

valid jetty
winged mantle
#

when would you use an int pointer other than output param

crude star
crude star
valid jetty
#
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"
    );
}
valid jetty
winged mantle
#

you can do it with a struct though

#

unless it's a weird compiler specific thing

crude star
#

struct intt { int value; }

pearl stagBOT
valid jetty
#

is nice

winged mantle
#

oh and of course c has vlas

pearl stagBOT
winged mantle
#

in c++ you need to use alloca

fervent torrent
valid jetty
#

being able to do int foo[bar] with an arbitrary rval in bar?

winged mantle
#

with arbritary expression

crude star
valid jetty
#

well yeah an rvalue would be an expr

winged mantle
valid jetty
crude star
#

alloca would mess up destructors

winged mantle
valid jetty
#

wow

winged mantle
#

gotta do std::vector

#

or whatever

valid jetty
#

std::span

winged mantle
#

whats a span

valid jetty
winged mantle
#

that doesn't explain much

#

its a slice?

valid jetty
#

a slice

#

yea

crude star
winged mantle
#

what would it do

valid jetty
#

static arrays can’t exactly grow in size so a slice/span works well

winged mantle
#

that sounds fun

crude star
#

can't unwind stack if you don't know the stack size

valid jetty
#

i know the stack size

winged mantle
#

seems to "work" with ints

crude star
#

huh

winged mantle
#

(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

native spruce
#

bwah

shrewd canopy
valid jetty
#

isn’t that boxed/heap alloced tho

#

afaik new is for heap allocations

winged mantle
valid jetty
#

boxing is not a rust term

#

c# and haskell use the same terminology

winged mantle
#

irrelevent languages

winged mantle
crude star
#

only rust uses it in the language itself

fervent torrent
#

god damn i'm a genius...

crude star
#

allocating on stack is dumb anyway

#

both the stack and the heap are in RAM

winged mantle
#

ram is your bedroom floor heap is the random clothes scattered around stack is the stacked books

jade stone
#

@winged mantle will clean up their room

winged mantle
#

this is not a self-referential your

jade stone
#

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

winged mantle
#

notified about?

#

clipboard stalking?

jade stone
#

when the clipboard changes

#

i am making a clipboard app

winged mantle
#

does wayland make it hardfer

crude star
#

execvp("wl-copy", "--watch")

lavish frigate
#

Don’t care about stack or heap or whatever im shitting in your ram and causing a pc crash

jade stone
green gulch
jade stone
#

there is an XDG Desktop portal for this

#

but kde doesnt support it

#

it has it's own dbus interface thing for it

shrewd canopy
lavish cloud
#

Wayland is supposed to do that

#

Unfortunately they forgot to ask both users and developers for feedback

fervent torrent
#

how can i edit this tooltip?

spark tiger
shrewd canopy
#

rust solves only memory safety issues, not security issues

native spruce
#

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

frosty skiff
#

heartbleed is a good example, and iirc the 2019 chrome zeroday was related to heap corruption that allowed for ace

crude star
spark tiger
wild coral
crude star
#

no reason to use pycord anymore

#

d.py is maintained again

wild coral
#

figured

#

discord bots r cool :3

wheat kernel
#

pycord is ass

fleet cedar
nimble quail
#

nothing too crazy just yet

hoary sluice
valid jetty
#

well how do you think the elle lsp works silly

#

parser? for what

ivory heath
# valid jetty

I don’t like the fact that here and golang this isn’t a explicit type

ivory heath
fleet cedar
#

Or social engineering

ivory heath
#

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

mild yoke
#

L rust

valid jetty
ivory heath
#

How do you handle variable shadowing?

valid jetty
ivory heath
#

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

valid jetty
#

in elle that doesn’t happen

#

if you use := in a tuple destructure it’ll shadow the previous variables

ivory heath
valid jetty
#

well, yes because as far as the compiler is concerned the previous variable no longer exists

#

it just resolves to the last defined x

valid jetty
ivory heath
#

What use?

valid jetty
#
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();

ivory heath
#

Oh yeah I guess it could be useful for that instead of polluting the name space

valid jetty
#

yeah

ivory heath
#

You have to be aware of what the type is updated to tho

valid jetty
#

it’s fine because there’s an lsp

#

you get hover diagnostics

#

(and it’s strongly statically typed)

ivory heath
#

I think code should be readable without a LSP

valid jetty
#

if you try to use the .close method and it hasn’t been unwrapped you’ll get an error at compile time

valid jetty
ivory heath
#

I mean you can infer what it does

#

I just like verbose personally sodalove

valid jetty
#

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)

valid jetty
ivory heath
#

Yeah that makes perfect sense

valid jetty
#

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

ivory heath
#

A warning, but not an error?

#

Pedantic to mean just means all warnings becomes errors

valid jetty
#

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

ivory heath
#

You miss out on compiler optimizations and safe assertions

valid jetty
#

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

valid jetty
#

you can yea

ivory heath
#

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

ivory heath
valid jetty
#

because thread safety

spark tiger
valid jetty
#

and anyway “mutable constant” is a contradiction

#

i think you mean mutable global static

ivory heath
#

I meant to use constant in quotes not literally

valid jetty
#

oh

ivory heath
#

Static means something else depending on the context

valid jetty
#

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

ivory heath
#

That makes me think of something I’m working on
.

#

I have mutable globals but I hate it

valid jetty
#

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
ivory heath
#

Yeah that sucks.

valid jetty
#

i don’t even need this bearocracy because the compiler is single threaded

ivory heath
#

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

valid jetty
#

@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

median root
#

yo do packages like pynput and pyatuogui support flatpak apps?

hoary sluice
median root
mild yoke
viscid grove
shrewd canopy
winged mantle
nimble bone
jade stone
#

okay

viscid grove
nimble bone
#

Apple ships git 2.39 😭

lavish frigate
#

it shall stay this way

~>git -v
git version 2.39.1.windows.1
nimble bone
#

That's better.

jade stone
#

nix only has git 2.49

#

@pseudo sierra fix

lavish frigate
viscid grove
nimble bone
jade stone
viscid grove
#

yeah

nimble bone
jade stone
#

but the CVE says otherwise

viscid grove
#

wow

#

paper spreading misinformation

jade stone
#

yop

pseudo sierra
jade stone
#

😔

pseudo sierra
#

shrimply use master trolley

#

also I'm pretty sure it's in unstable small

pearl stagBOT
valid jetty
#

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...

▶ Play video
#

this is kind of awesome

crude star
#

this sucks who taught the aibros yield

valid jetty
#

no keep watching

#

watch the whole thing

#

it gets better and better

valid jetty
#

pls watch the full video this is actually pretty cool

crude star
#

you can replace await with yield but it creates the same problem as async 😭

jade stone
#

You posted effect here before and I didn’t like it then

valid jetty
#

using yield, you can bubble up tagged errors

#

which you cant do with await

#

but there is more interesting stuff

crude star
supple whale
valid jetty
#

just watch it 😭

#

omg watch the video

supple whale
#

and old node users know how insane of a pain that is

shrewd canopy
valid jetty
#

it is not like old nodejs callbacks

supple whale
#

it is just re-wrapping them

crude star
#

its half an hour long no one is watching

supple whale
#

which is awful

valid jetty
nimble bone
#

lc.gpt tldr

visual shellBOT
# nimble bone lc.gpt tldr
> This video introduces "Effect" as a powerful al


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 catchTags for specific error types.
    • Data Parsing: Includes @effect/schema for runtime validation and parsing.
    • Enforcing Return Types: Uses makeEffect to 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.

supple whale
#

this is just nodejs callbacks, just more complex

jade stone
valid jetty
#

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

jade stone
#

this is worse than async/await

supple whale
#

so you get x10 the boilerplate, x0.1 the readability and pure pain

supple whale
#

TLDR typescript doesnt implement @throws

#

and with this you can have type safe errors

jade stone
#

eh

#

not worth it

supple whale
#

yeah

crude star
#

errors are a skill issue

jade stone
#

just use a discriminated union if errors matter that much

supple whale
#

i 100% agree that lack of error support is a BIG problem in TS

valid jetty
#

it has much more than just type safe errors however

jade stone
supple whale
#

JSDoc solved it decades ago

#

simply no1 implemented the spec

valid jetty
#

it has requirements for dependency injection, a ton of utility functions, etc..

crude star
#

if my code throws an error its a user problem

jade stone
#

i should really look into DI sometime

frosty skiff
jade stone
#

never really gave it much thought

frosty skiff
#

just tell the user not to make mistakes

#

😁

supple whale
jade stone
supple whale
#

i arrived at a simple solution for errors in TS tho, if its a promise, then it throws an error, always.

frosty skiff
#

I love DI

supple whale
#

i cant imagine anything without DI

jade stone
crude star
#

it's a nonsense term tbh

supple whale
#

yeah

#

so TLDR

frosty skiff
jade stone
frosty skiff
#

constructor hell

#

❀

jade stone
#

horror

frosty skiff
#

it's why people use

#

stuff like koin

valid jetty
frosty skiff
#

for di

jade stone
supple whale
frosty skiff
jade stone
frosty skiff
jade stone
#

INSANE

supple whale
frosty skiff
#

I'm writing my compiler for x86 -> jvm in kotlin

jade stone
#

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;
}
supple whale
frosty skiff
jade stone
frosty skiff
#

im guessing because

jade stone
#

no

frosty skiff
#

oh

jade stone
#

this is desktop jvm

frosty skiff
#

why is it in java then

jade stone
#

(cba to learn jni for kotlin)

fleet cedar
#

It's not like jni is any different in kotlin

#

Still the same jvm

frosty skiff
#

I love jni i create 1000 dummy dll's for my drm

supple whale
#

damn, discord already sold my data, that was fucking QUICK

jade stone
supple whale
#

maybe

#

idk

jade stone
#

yeah

#

it is

supple whale
#

jesus

frosty skiff
#

its just external func nativeshit(): string rather then public native string nativeshit();

#

unless that isn't what u mean

jade stone
#

guh

#

i probably could do it in kotlin

#

but meh

frosty skiff
#

why don't u just write it to work outside the jvm 😭

frosty skiff
#

like

jade stone
#

my app is in kotlin

frosty skiff
#

oh

jade stone
#

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)

frosty skiff
#

what is kotlin used for then? the gui etc

jade stone
frosty skiff
#

I see

jade stone
#

the ui is compose destkop

#

(wanted to learn something new)

frosty skiff
#

I've been using skia a lot recently for rendering stuff myself

#

and it's been awesome

jade stone
#

neat

frosty skiff
#

mostly via tiny-skia in rust

#

idk i love jni

#

ive done so much with jni

#

i could probablyh talk about jni all day

jade stone
#

i need to render arbitrary html for this project tho

#

so that will be fun

frosty skiff
#

oh interesting

jade stone
#

(no js tho)

frosty skiff
#

yeah

jade stone
#

@signal oak how does java handle kotlin typealiases

#

guhh mugman left

frosty skiff
jade stone
#

oh

#

you cant

#

just use the underlying type

supple whale
#

right, dont do shit while updating drivers

frosty skiff
#

fixes all my issues ever

austere idol
lucid trail
#

i got a new keyboard!

ionic lake
#

congrats!

dense sand
#

vscode release notes be like:

  • ai
  • ai
  • more ai
tired vigil
#

Tf is MCP anyway

#

Also aren't half of vscode updates just them adding special integrations for copilot chat?
I hate this sm

dense sand
#

😭

tired vigil
#

That would be a much better feature tbh blobcatcozy

jade stone
fervent torrent
#

does anyone know how i can edit this tooltip?

ornate quiver
#

I love jni

valid jetty
ornate quiver
#

jni is fun

valid jetty
#

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);
}
#

😭

jade stone
ornate quiver
#

there's quite a bit of footguns that you have to avoid

jade stone
dense sand
jade stone
dense sand
#

why dont you use jna or ffi 😭

jade stone
#

what ffi does java have

dense sand
#

something like this

#

but only if you use new java version

jade stone
#

i'd rather use jni

#

cba to bother with JNA

#

and im limited to java 21

valid jetty
#

why so much bloat to call a C function

jade stone
#

yeah

dense sand
#

i mean, tbf im more comfortable with using jni-like syntax too

ornate quiver
#

to make it "safer' or something

jade stone
#

it seems a lot more complicated then it needs to be

dense sand
#

its just that jni will soon become deprecatzed feature in new versions of java

jade stone
#

also what's dev.java

#

who owns that

ornate quiver
#

jni is so much more simple

ornate quiver
dense sand
ornate quiver
#

it's just turned off by default for security

ornate quiver
#

deprioritized maybe sure

#

jni can't ever go away

jade stone
#

i feel like there's already decades of JNI code out there

#

you cant just break that

dense sand
#

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)

jade stone
#

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

valid jetty
#

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

hoary sluice
#

elle more like js

spice token
#

So do yall play games here

#

It says pro gaming

timber root
#

yes

lavish frigate
#

no

ionic lake
ionic lake
#

got me

gaunt whale
lavish frigate
timber root
lavish frigate
#

Get this Roblox garbage out of my precious programming channel!!!!!!!!!

#

‌‌‌‌‌

spice token
lavish frigate
# spice token 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!!!!!!!!!

timber root
#

new pasta just dropped

lavish frigate
#

think its really funny how every modern language now uses "let" for variable declaration

austere idol
#

zig uses const and var

lavish frigate
#

thats why nobody uses zig

austere idol
lavish frigate
#

no

#

i just dont want to open this channel and see "tycoon" i want to open this channel and see programming nerds

austere idol
#

oh yes, r*blox uses its own strong typed fork of lua

timber root
#

what if we rename this channel to progaying next june

lavish frigate
#

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!!!

frosty skiff
#

I've been writing something to help with reverse engineering stuff related to JNI recently in Rust

frosty skiff
shrewd canopy
austere idol
frosty skiff
#

WHAT THE FUCK IS A STABLE CFG

#

WHY IS THERE 5000 BRANCHES

#

WHAT IS GOING ON ‌

austere idol
#

the sin against everthing human

frosty skiff
#

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

shrewd canopy
#

glad the library i am reverse engineering aint obfuscated at all

frosty skiff
#

what is even going on ‌

austere idol
frosty skiff
#

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

hoary sluice
#

@valid jetty @placid cape advantage 360 next??

crimson sparrow
supple whale
#

and what phone do you have? yes.

ornate quiver
hoary sluice
#

yes thats the whole point

crude star
spark tiger
ornate quiver
crude star
#

bottom of readme

native spruce
jade stone
crimson sparrow
# jade stone 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...

▶ Play video
#

Realizing it was 9 years ago 😭

jade stone
lavish frigate
lavish frigate
#

nop

tired vigil
#

Eww

austere idol
#

unreadable

lavish frigate
#

does converting math expressions into postfix make sense in a language? i found it easier than making an ast

fleet cedar
#

Sure, a lot of bytecodes do that

lavish frigate
#

cool, tbh i already implemented it before asking myself that question

spark tiger
#

who that wires

lavish frigate
#

wtf is bro doing

frosty skiff
#

I'm writing an obfuscator for nix

shrewd canopy
#

Why does n*x needs an obfuscator

frosty skiff
#

It really doesn't

crude star
#

its already obfuscated

frosty skiff
#

❀

crude star
placid cape
#

lmao

frosty skiff
#

origianl

ornate quiver
#

what is bro doing

native spruce
#

them showing off private apis is crazy

frosty obsidian
ornate quiver
#

we need this but built in to compose

#

its 2025 and theres still no conclusive way to figure out recompositions

jade stone
frosty skiff
#

I want to find a way to get around nix repl and I have a few ideas

#

although they're all complex

jade stone
lavish cloud
#

the worst possible way to do i18n on switch for sure

lavish frigate
#

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)

ivory heath
#

HAI MAC OS

lavish frigate
woven mesa
lavish frigate
#

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

woven mesa
lavish frigate
#

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...

▶ Play video
#

the glorious giant ass commit with the "add a ton of new stuff" title

sly violet
#

who is @vale geode

paper scroll
#

i fear i do that

#

sometimes i commit but not push when i add something but i usually forget to

lavish frigate
#

yea thats what happened here 😭

hollow locust
#

is there a known alternative to old TextElement? the one that aside from being a component also had Sizes and Colors nested objects

lavish frigate
#

using the win32 api always makes me want to explode

frosty skiff
#

I am implementing IR for Nix

lavish frigate
shrewd canopy
#

At least its not javascript tho

crude star
#

all of this is valid javascript

lavish frigate
#

i think its c++ because the tweet author primarily does c++

winged mantle
#

new creates pointer which uses ->

ivory heath
#

you owe me. i got muted for that

winged mantle
#

guh wait you're obviously kidding

#

it would obviously use :: too

spark tiger
frosty skiff
spark tiger
runic sundial
lavish cloud
runic sundial
lavish cloud
#

how so

runic sundial
#

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

lavish cloud
#

rip

runic sundial
#

Shit fucking sucks

#

Only works if you follow their special rules

#

apitrace is goated thoe

lavish cloud
#

meanwhile I gotta learn aarch64 binary because keystone is gpl sobb

runic sundial
#

works with everything

#

Been working on my own shaders mod on 1.7.10

lavish cloud
#

bro why are you even on 1.7.10 smh nobody plays that shit anymore

lavish frigate
#

i will not take this hate

runic sundial
lavish frigate
#

1.7.10 is the version i have the most hours on i think

#

maybe a close second behind 1.8

runic sundial
#

Been working on a modpack for 1.7.10 for years now

lavish frigate
#

thats the version i grew up on that has all the mods

runic sundial
#

No point moving tbh

crude star
lavish frigate
#

if you search for recommended modpacks rn people will recommend you modpacks on 1.7.10

runic sundial
lavish frigate
#

just this week i was recommended ftb infinity evolved which is in fact on 1.7.10

crude star
#

im gonna use log4shell on you

crude star
#

who is that

lavish frigate
runic sundial
#

what then

crude star
#

there's nothing important in my downloads folder

runic sundial
#

ok

#

then delete it

#

for me

crude star
#

i do that often

runic sundial
#

next delete app data

crude star
#

nop

runic sundial
#

now we know what you fear

frosty skiff
#

I remember a minecraft cheat using it

#

to make it seem like you didn't have to download the client lol

runic sundial
frosty skiff
# runic sundial ????

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

frosty skiff
#

I know

runic sundial
#

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

frosty skiff
#

Also, iirc JDWP still has synchronization issues too

runic sundial
#

I only test against Temurin

frosty skiff
#

Same with the protocol being ass

runic sundial
#

protocol works in the background, i only do the check to see if the intellij debugger is connected

frosty skiff
runic sundial
#

so like

#

what

frosty skiff
runic sundial
#

i don't care about GraalVM/OpenJ9

#

No point in them. At all.

frosty skiff
runic sundial
#

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

frosty skiff
runic sundial
#

What diagnostic data in particular?

frosty skiff
#

I know they give a lot of information related to its IR

runic sundial
#

fair enough

frosty skiff
#

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

runic sundial
#

I have my JProfiler licence and that gets me plenty far

frosty skiff
#

I don't rlly use jprofiler as much as I used to but I still think it's nice to have

runic sundial
#

At the end of the day most of my code ends up being GPU limited anyway

frosty skiff
#

rendering stuff?

runic sundial
#

Yop

frosty skiff
#

dip

#

rip*

runic sundial
#

Few months back wrote a mod to add Tracy support with GPU profiling for 1.7.10

frosty skiff
#

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

runic sundial
frosty skiff
#

I am working on a transpiler for Nix

lavish frigate
pseudo sierra
#

I kinda wanna dm them like yo I'll have a look and make it work for 5k trollelely

lusty wagon
lavish frigate
lusty wagon
#

Oh right

valid jetty
#

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

frosty skiff
valid jetty
#

LMAOOOOO

#

THAT IS COMPLETELY UNINTENTIONAL

tired vigil
lavish frigate
#

Horrible

shrewd canopy
valid jetty
#

rust documentation is so deep..

valid jetty
#

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

crude star
#

how do you "accidentally" add unicode support

spark tiger
#

who is evil vee

valid jetty
#

and then i just have to properly encode the symbols in the qbe file where necessary and it just works

#

lol

winged mantle
#

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

valid jetty
#

if you cast a u64 to a u32 you get the lower 32 bits (or x & 1 << 32)

jade stone
winged mantle
#

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

winged mantle
#

i was planning to implement a programming lang for fun

#

and if i didn't realise this i would make it work like that

valid jetty
#

well

#

you wouldnt because the intermediate representation would do it for you

#

but yes

winged mantle
#

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

valid jetty
#

im laughing so hard

supple whale
#

alcohol was involved in decision-making

fleet cedar
#

I got 10/28

valid jetty
#

i think i got lucky

lavish frigate
#

I guess I have too much common sense

tired vigil
#

I guessed most of the questions 😭

magic shale
#

i hated dates before and now i hate them more

#

i have to know what the new Date() implementation looks like

shrewd canopy
#

datetime.datetime my beloved

hoary sluice
#

u need to append "at" to [-2] of the print function name

valid jetty
hoary sluice
#

not pechat'

valid jetty
#

idk russian i used google translate

#

:3

ruby wave
#

Hello, do you know where I can find Vencord configs?

shrewd canopy
valid jetty
#

language no.3

#

i did german too

#

@royal nymph love?

#

god german is so long đŸ˜Ș

crimson sparrow
valid jetty
#

and lastly, australian

crimson sparrow
valid jetty
#

the upside down alphabet is still a unicode alphabet

#

just like cyrillic or japanese

fleet cedar
valid jetty
#

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

crude star
#

type before field 💔

glacial mirage
#

do you say "this is my dog max" or "this is max (he's a dog)"

crude star
#

max is a dog

#

worst argument I've ever seen

glacial mirage
#

thank u

valid jetty
#

my terminal is a bit broken but it works

fleet cedar
valid jetty
#

"Max is in a state of existence" sounds funny

fleet cedar
#

Aren't we all

crude star
#

im not

winged mantle
#

me neither

native spruce
#

maybe make an extension

crude star
#

@young flicker is not decodable

woven mesa
#

do u want some help

#

i can help

valid jetty
# valid jetty

idk who would ever want and/or need this but its here i guess

woven mesa
#

why the fuck would i make an app with flutter

#

that shit is horror

#

elle!

frosty obsidian
woven mesa
#

i think i would rather not

frosty obsidian
#

you just have to learn dart

woven mesa
#

i have dealt with flutter before and i do not like it

#

i have written dart

frosty obsidian
#

i can also tell when an app is flutter just by using it

woven mesa
#

wait im in the nerd channel

#

how did i end up here

#

i might be going insane

frosty obsidian
#

someone pinged you

woven mesa
#

oh

#

no one pinged me here i think

#

i was pinged in regulars

#

im going insane

frosty obsidian
#

@woven mesa

woven mesa
#

that was 2 hours ago

frosty obsidian
#

the channels are also next to eachother

woven mesa
#

my chcannel list keeps them apart

#

guess im insane

frosty obsidian
#

idk then

woven mesa
#

yea

#

sidelo

#

i need an ipod ipa

frosty obsidian
#

subconsciously started talking about a programming thing in a programming channel

woven mesa
#

whats my youtube byundle id

#

com.llsc12.youtube

frosty obsidian
#

where is 4k hdr raytracing

woven mesa
#

idk man its a single cpu core

valid jetty
woven mesa
#

omg

#

twinning

valid jetty
#

: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,,

woven mesa
#

i didnt use raylib for the rendering

valid jetty
#

wait whatttt

woven mesa
#

i allocated a block of memory to write my pixel data to

valid jetty
#

wait is the fps counter from sdl then

#

or what

woven mesa
#

i literally like

valid jetty
#

oh i see

woven mesa
#

wrote a 3d renderer

valid jetty
woven mesa
#

i use raylib for windowing and drawing my framebuffer to a Texture2D to show on screen

#

and also mouse capture and other inputs

#

rate đŸ„ș

valid jetty
#

looks so good

#

what is it written in

#

C++?

woven mesa
#

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

valid jetty
#

swift doesnt sound like it should be fast but its arc lmao

woven mesa
#

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

winged mantle
#

I remember ignoring warning that I was modifying const pointer in c

#

c const pointers are based because they're not actually const

woven mesa
#

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

valid jetty
#

i hate languages that treat you like a baby

woven mesa
#

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

valid jetty
#

ok fair but thats because a lot of swift depends on objc which depends on C

woven mesa
#

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

brisk baneBOT
#
Ayame Stats
Bot Started

<t:1749550809:R>

CPU Usage

1.5%

Memory Usage

1.4 MB

Swift Version

Swift 5.10

woven mesa
brisk baneBOT
#
gbp to usd

$1.32

woven mesa
#

true

spark tiger
jade stone
spark tiger
jade stone
#

yeah

#

thats what i thought

#

i dont like rust that much

#

but i dont like go either

spark tiger
#

one time they benchmarked the same program in go and rust in
 debug configuration

jade stone
spark tiger
#

and when was pointed out, was just “well i just used whatever the default build option is”

lucid trail
spark tiger
#

yeah

austere idol
#

thats how it looks like in c

valid jetty
#

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 :'))

ionic lake
#

elle code

winged mantle
#

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

valid jetty
#

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

fleet cedar
#

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

valid jetty
#

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

fleet cedar
#

No, but rust has 98u64

valid jetty
#

yeah true

winged mantle
#

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)

valid jetty
#

integer literals in rust are not i32, they can take the shape/absorb the type around them

winged mantle
valid jetty
#

if your vec has an explicit i32 then the other integer literals absorb the i32 and also become i32

winged mantle
#

the lsp is wrong...

valid jetty
fleet cedar
#

RA isn't always accurate with the fine details

valid jetty
#

you could write vec[1i32, 2, 3, 4, 5] and the error would go away

winged mantle
#

i can't tell if this is genius or stupid

valid jetty
#

if you wrote 1u64 the vec would be Vec<u64> because the other int literals also absorb into u64

winged mantle
#

but it's certainly something that i haven't seen in other languages

valid jetty
#

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

winged mantle
#

but... how does it work