#development
1 messages · Page 198 of 1
wtf
maybe it has immutable attribute set or something
I can't check right now
idk why adding write perms would bypass that if so but
any idea how to get CF tunnles running on jb iphone ?
ik theres ngrok but i need vnc
@visual meadow have u done anything like that ?
No
cf tunnels?
Cloudflare is think
can somone with dev ACC get me this watch profile https://developer.apple.com/services-account/download?path=/iOS/iOS_Logs/loggingiOS.mobileconfig
this one
oh it made me sign in tho ?
It makes you sign in but after that it just downloads
what's complicated about it
yall
maybe im just silly
but there has gotta be a simpler way to do this
basically
i want to allocate a string on the heap and then automatically update it when a variable changes
so i do this
string bouncesString = malloc(1);
defer free(bouncesString);
to initialize
and then lets assume i have this variable first right
int bounces = 0;
this variable changes and i want to put it into a string to put on the screen
first i get the length of the string with snprintf
int length = snprintf(NULL, 0, "Bounces: %d", bounces);
then i realloc
bouncesString = realloc(bouncesString, length + 1);
then i write to the memory
sprintf(bouncesString, "Bounces: %d", bounces);
then i use the string
DrawText(bouncesString, (screenWidth - MeasureText(bouncesString, fontSize)) / 2, 100, fontSize, YELLOW);
theres no way this is the easiest way to do it
however this is the approach i found when looking through the stdio docs lmao
meanwhile in python or something
# init
bounces = 0;
bouncesString = "Bounces: 0";
# update
bouncesString = f"Bounces: {bounces}";
lmao
well int_max is 10 digits so you can just make the string big enough to hold that many and not realloc or check the length
great that means i dont even need to use the heap i can just stack allocate it
thank you :3
i can just
// init
int bounces = 0;
string bouncesString[strlen("Bounces: ") + 10];
// update
sprintf(bouncesString, "Bounces: %d", bounces);
almost the same as py
and what does git diff say
git diff --color=always HEAD~ HEAD | tee
the only correct way ^
what does that even do
diff the last commit?
exactly what you think it does but better
couldn't you technically omit the second HEAD
also how's it better
regular git diff with no flags is paginated and colored already
what does the tee even do
tee makes it not open in less
oh
binary files
Wdym copy pasted the repo folder, I'm trying to visualize what you did
@grave sparrow hey arm expert: is there a more aapcs way to do this?
https://stackoverflow.com/questions/62812383/most-effient-way-to-push-all-registers-to-stack-in-arm64
like copied the entire folder or just .git?
something something midfunction hooking 
-a is the only way
what happens if you git diff --stat
or you could try moving the file that it says is modified to another spot and then git restore it, and see if you can compare a difference now
❯ cat ~/.zsh_history | grep "cp -a" | wc -l
377

I hate the stack alloc every line tho wtf is that about
capt
That would've been useful to know
It's definitely not checked out
Hold on
I can't read the docs on my phone great
go back to the old repo and see how big the file is
i wonder if something was cached
what
It just said it was 111 bytes a moment ago
no
you're just stupid
Send me the directory fr
the only thing I can think of is maybe you didn't actually have the file stored in LFS in the previous repo
It definitely shouldn't be 333333 bytes in the index
but git says it is
it should be the 111 bytes in git because it's just a metadata file
but in the index it should be 111 so it's weird that it thinks it's being changed from 333333 (which it shouldn't be) to 111
Let me go home and do some investigation with a gif lfs repo
@grave sparrow for the record did you ever run git lfs install
run git lfs install again and see if it fixes it 
or git lfs checkout but that doesnt really help figure out why it happened
on a fresh clone?
oh i thought this was only talking about copying a clone
weird
@grave sparrow so what do the lfs files look like inside, are they text files with the metadata
These pointer files usually start with the line
version https://git-lfs.github.com/spec/v1.
what about git lfs pull
it should automatically do it but try it anyways
are they still just text files
on github website when you look at the file, does it say stored with git lfs
that explains everything

so its committed to the repo without using git lfs
youll have to delete it from the repo in a commit and then add it with lfs
what does .gitattributes look like, is it configured to make *.dylib stored in lfs or whatever
no because its not stored in lfs
i think it wants to change it to an lfs file
look at .gitattributes
@grave sparrow no stack space? wtf?
no Im at call #1 and only the 5th instruction in!
x8 is the reg I modify so I don't need to save it
I forgo
8 != 16 align
im like 99% sure you need "stp x8, x9, [sp, #-16]!\n" for alignment
but i could be very wrong
i was in the process of typing it out before you said it
I want working code copy pasted before I do good neat code
cool btw this code doesn't work at all lmao
not your code but that stack overflow code

im like 99% sure you need 768 bytes
https://www.diffchecker.com/u2OBu6X3/ bruh moment
yah it does idk why it failed the first time
thanks
thats stupid tho because im preserving lr I can't use ret, so I have to use a register to br back shame theres no br add reg like you wanted
@grave sparrow
arm devs when they have to implement new features instead of sitting at their desk making free money 
it is literally confirmed that nvidia work environment is that
just add and shifts
lsl
just listing all the options
nvm then
exception hooking
oh you kinda already said that
idk its built into ellekit
https://github.com/evelyneee/ellekit/blob/main/ellekit/Languages/C/Hook.swift#L105-L112
oh stock yah I doubt that
windows go sicko mode
secweritwy 😵💫
pthread_create
- page codesign?
- jit?
breakpoint method not work on stock anymore?

apple just ruining shit to ruin shit
on yourself you can do both
you can still set exc handlers on remote processes afaik
let llbpdig = dict.get("LLB")
.unwrap()
.as_dictionary()
.unwrap()
.get("PartialDigest")
.expect("Partial Digest not found")
.as_data()
.unwrap();
rust 
dict.get(comp)
.and_then(|x| x.as_dictionary())
.and_then(|x| x.get("PartialDigest"))
.and_then(|x| x.as_data())
.expect("Failed to get Partial Digest")
(you can do cooler optional chaining but still funny)
ok that has to be done better as an if let
actual imperative code
When you ask gen AI to solve the math problem
as in how
like just getting rid of the last .expect() in exchange for if let Some(llbpdig) = ?
isn't dict.get just returning an Option
change the entire and_then chain to just be lines of code in the body of an if let
wouldnt that make a small pyramid tho
What
Wait you're literally just using x every time
That should just be a dot chain
?
those are closures
each time the type is diff
wtf where rust as a functional language
also wtf is a dot chain
is that not functional programming
or atleast return chaining
which one of these and_then's return option
what type is dict.get
dict.get(comp)?.as_dictionary()?.get("PartialDigest")?.as_data()
something liek that
hard to know without seeing code for what the types are
oh isn't that just doing the same thing except instead of .and_thening you just return a error in the function if there is any
is there so much of a diff
.
do you really want the and_then version
it looks cool
after optimizations yes
if your definition of cool is being horrifying and taking up 10x the space 
also how would i do that in a function that doesn't return a Result

wouldnt i need to do some ass thing where i either put it in another function or closure
then end up using .expect anyways
💀
{
dict.get(comp)?.as_dictionary()?.get("PartialDigest")?.as_data()
}.expect("fail whatever")
probably a better way to do this but i forgor
this looks more ass than .and_then

no
if let Some(c) = dict.get(comp) {
c.as_dictionary()?.get("PartialDigest")?.as_data()
}
maybe that works
what do you mean
also the result that comes from the ? operators still has to be dealt with
so after that block comes a .unwrap() or .expect()
👨
im making structs in elle
keyword ideas pls
struct or def?
struct AudioStream {
long buffer;
long processor;
int sampleRate;
int sampleSize;
int channels;
};
struct Sound {
AudioStream stream;
int frameCount;
};
struct definitely
house
each class is called a city made up of a bunch of houses
and the entry point of the program is called customs()
when something goes wrong you alert police::buffer_overflow_department
idk why i came up with this i'm just bored, struct sounds okay
a house may not contain itself directly or indirectly unless it is called leaves
in which case the compiler executes a fork bomb
lmfao
You can't register exception handlers for your own proc??
I literally can't believe that for some reason
like that just cannot be true
setting thread states was entitle'd one day randomly but exception handlers??
ellekit does it
plus dopamine doesn’t modify that stuff
@grave sparrow wtf are you talking about
ellekit uses mach apis to set exc handlers to hook functions
it works on all ios versions
what else is there to say
uh ok
still you would need to store a 64bit address in the instruction
and that takes many instructions
ok ive confused myself
in qbe, types can be aggregate aka structs right
so you can write a declaration such as
type :Test = { l, w }
%tmp =:Test call $getSomething()
where :Test is the type
however to actually create one of these structs you need to do something like this
type :Test = { l, w }
export function w $main() {
@start
%test.addr =l alloc8 12
storel 10712512, %test.addr
%tmp.addr =l add %test.addr, 8
storew 252, %tmp.addr
ret 0
}
i can get the compiler to generate this
but how do you get just the straight up memory as a type like before
because all you have when you create it is a pointer to the start of the allocated memory
i also do this when making local variables so i can get their stack address
%i.addr =l alloc4 4
storew 100, %i.addr
%i =w loadw %i.addr
but that doesnt really make sense for structs??
like you cant exactly do
%stream.addr =l alloc4 28 # longs are 8 bytes in this case
%tmp =:AudioStream call $GetAudioStream();
store:AudioStream %tmp, %stream.addr
%stream =:AudioStream load:AudioStream %stream.addr
storing an address on stack takes instructions
Suggestions ? Ik I should like make it not over lap but do I make the text smaller ?
Like here ?
Like do another drop down like I Alr have ?
(Also ik padding is messed up)
sort of ya
mobile phones have a lot more vertical than horizontal space
omg
why is this being generated
im going insane
i tried to debug it
this name isnt even used ever when assigning anything anywhere in the compiler
HOW IS IT BEING EMITTED
i even checked the statements in each block generated by the compiler
how in the heck is it emitting sound.addr
.
the generated string literally does not contain sound.addr
has anyone extracted the apple intelligence on-device model weights yet
Is it bad to have it scroll i kinda wana keep this like floating thing. Like a dynamic isldand kinda thing
is what u want to do is just changing pc without requiring another reg?
what i’m saying is that idea doesn’t make sense since youd need to movk parts at a time and it would just be corrupted until the address is complete
better get hired at arm cuz they aint gonna do shit 💀
please for the love of god remove the actual scroll thumb bar
yea il move it down
idk if IOS lets me do that, -webkit-scrollbar::{ display none} maybe
if on mac can spin up a hacky kext lol
actully movile isnt gona have that
or just change the width of it to not be like 100% of the scroll view
wait is this not just the jump insn
piracy
could handle it like how the kernel handles svc, and just set the thread state tbh
its for linux ISO's 

also I don't see the point of arm ever adding that insn because 1. more complexity and 2. you can already achieve this with a little extra instructions which wouldnt be a problem for code writers
also can you not just use page tables for this
remap to somewhere closer
@ashen canyon @placid kraken
good morning tweakers
desktop* (yes ik colors are off)
bash -c "$(curl -fsSL https://raw.githubusercontent.com/theos/theos/master/bin/install-theos)" ran this command to install tea os
and um
it is installed but running $THEOS does nothing
==> Dependencies have been successfully installed!
==> Checking for WSL...
==> Seems you're not using WSL. Moving on...
==> Checking for $THEOS environment variable...
==> $THEOS has not been set. Setting now...
==> Checking for Theos install...
==> Theos appears to already be installed. Checking for updates...
Already up to date.
==> Notice: Visit https://github.com/theos/theos/commits/master to view recent changes.
==> Checking for iOS toolchain...
==> A toolchain appears to already be installed.
==> Checking for patched SDKs...
==> SDKs appear to already be installed.
==> Theos Installer: Theos has been successfully installed! Restart your shell and then run $THEOS/bin/nic.pl to get started.
xash@archiemarchie ~/t/bin (master)>
did u restart ur shell ?
dont call anyone that

apperantly fish shell is just ass
god but i love the autocomplete
okay
ok. Jce i am making a tweak
to get that juicy DEVELOPER role zzz
i am ma
fa
fr
err moderators they’re abusing perms
with enough money anything is possible
Not with Aaron
He costs way too much
@radiant idol
function callableArray<T>(...array: T[]) {
const _closure = (index: number) => index;
const typedClosure = _closure as unknown as typeof _closure & typeof array;
array.toString = function() {
return `[${array.map(element => JSON.stringify(element, null, 2))}]`;
}
const proxy = new Proxy(typedClosure, {
get(_, prop: string, __) {
return !isNaN(+prop) ? array[+prop] : Reflect.get(array, prop, array);
},
set(_, prop: string, handler) {
!isNaN(+prop) && (array[+prop] = handler)
return true;
},
apply(_, __, [index]) {
if (typeof index === 'number') {
return array[index];
}
return null;
}
});
return proxy;
}
Stop
Playing audio on apps while ringer switch is in silent. Dev role worthy or no ?
Well what do you personally think ?
Not long 💀
50 lines
I modded my xbox do i get developer role
I made a simple game looking step by step from a guide. Also working on a similiar game myself without guides but i kinda got stuck on it so doing tweaks rn
All those aside i hate this "feature".Just because i don't want my phone ringing like crazy doesn't mean i don't want to hear my game lol
i have your solution
its called
✨ Do Not Disturb ✨
No thanks
Thats even worse imo 💀
I hate it so much so that if i had a jb its one of the first things i would get rid of
why would you do this
bored
but the callable array part was easy
the hard part was to make it typed
so that indexing and calling the function returns the right type
thats what this
const _closure = (index: number) => index;
const typedClosure = _closure as unknown as typeof _closure & typeof array;
``` does
i mean doesn't ios just let you use critical alerts for this
yeah i know that wasn't a thing at some point but still
but yeah you can just bypass silent mode if you use the right kind of stream xd
i'm almost sure there's app store apps that do this
structs were too complicated so i did non-base-10 literals
use std/io;
fn main() {
long a = 0xDEADBEEF;
int b = 0o273451456;
int c = 0b111010011011111010010100101;
printf("a = %ld\nb = %d\nc = %d\n", a, b, c);
}
and i also cleaned up the function return type inference really heavily
@grim sparrow Is the new porter robinson album good
russian roulette is banger
literately
im this close 🤏 to shooting myself over JS
Programmers when they are told to deal with JS
Yeahhh
So good
is this an actual language
SwiftScript
they should give me dev
thats what you call a skill issue
imagine being sent into despair just because a language is a little silly
it’s just typescript
there's no way
Sure, this is just the playback category in AVFAudioSession
Still useful in games as they are mostly muting audio when in silent. Also idk about dnd or critical alerts i don't like those kind of workarounds much
that's a bit worse but i forced myself to basically take a crash course on it because i needed a fix for a node package i had no alternative for
however that function is beyond my scope (wordplay not intended)
what’s thr windows version of dyld
that like finds dlls to inject them during runtime but windows
The DLL loader is the part of the operating system (OS) that loads DLLs and/or resolves references to DLLs.
Doesn’t even have a cool name 
dyld is literally just DYnamic Link eDitor
you could call that the DLLL technically
💀
rundll32
that one was a bit obvious
32 bit? in this day and age? 
no it's still named 32 for the 64 bit one
average windows
the Link iDentIty eDitor?
honestly it would break things renaming it
the fuck did they do to the acronym
the most windows thing ever
apple would simply not care
i mean, it's something in system32 why rename
because it wasn't one
ld = linker
id = identity
😭
wait that just says linker identity then
and the shit does that mean
that too
so dyld was supposed to be the DYnamic LoaDer ?
but yeah if ld is the command for your linker ldid does make some sense
guess that makes sense
Linker Dynamic edition
well it just calls LoadLibraryExW (rundll32)
SetWindowsHookExcan be used to inject a DLL into another process
yeah that's about right
rundll32 is more like
a symbol finder in some cases
https://learn.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-setwindowshookexa
win32 is surprisingly quite documented
oh and one more thing, you'll commonly see methods ending in A or W and wondering what the hell the differences are
Win32 APIs often support both -A and -W variants. -A variants recognize the ANSI code page configured on the system and support
char*, while -W variants operate in UTF-16 and supportWCHAR. Until recently, Windows has emphasized "Unicode" -W variants over -A APIs.
i haven't even looked into windows development that much
wchar_t is just a macro for implementing wide chars
we should call it Alfie
We’ve always seen eye to eye Kirb
the DoJ suing you for self-preferencing APIs will do that
I meant other Alfie @hasty ruin

🤝🤝🤝🤝
now will you move to Chariz

@hasty ruin aurora dash better 
NXE is undeniably the best
Ty I’ll listen
It’s very indie pop/rock
i don’t like most electronic so we’ll see
nah blades is the best
Blades is ugly 👎
freestyle has a blades theme anyway
So it’s gotta be superior to aurora

i like my coverflow games tho 
brat is the only electronic album ive liked since nurture
Whereas it’s my favourite group of music :3
The despair and pain happen after you have taken the first step into learning JS. Just like what happened to Peter in that gif
@radiant idol what do you think of my drop down
Seems fine
russian roulette is good
the bridge is well done
plus it’s written by a member of bleachers wtf
porter still has a place in my heart tbh he makes beautiful melodies
this is so good
It bugs me that this very much isn't the output of apt-get
true
the homebrew store for aurora though...
Just soldered my finger 👍
TIL adding 'hidden' as an attribute to an html element hides it
Why ur room so
Not my pic
You made that ?
is there a discord server for apple development not related to jailbreaking?
yea
it works to
for linux ISO's *
try the theos server
they are good
usually know*

bruh
it was Moz docs, weird
whats the best way to do sorting? like subviews/children bassed of a property/attribute
(like the concept? or like fundimentals?)
in general quick sort
if you want to sort in js tho,
you need to have a way to order each item
so if you wanna sort lexicographically
i think its something like
myArray.sort((a, b) => a.localeCompare(b))
chat gpt gave me sm an i made it work ```js
function sortTorrentsByName(){
const torrents = Array.from(document.querySelectorAll("torrent"));
torrents.sort((a, b) => {
const nameA = a.getAttribute("name").toUpperCase().replace(/./g, ' ');
const nameB = b.getAttribute("name").toUpperCase().replace(/./g, ' ');
if (nameA < nameB) {
return -1;
}
if (nameA > nameB) {
return 1;
}
return 0;
});
torrents.forEach((torrent, index)=>{
torrent.style.order = index;
});
}```
is this bad ?
yea
wont work because you cant really compare strings with < or >
use localeCompare
it works 🤷♂️
does it work for if the strings start with the same first char but the rest are different
so like car and cat
just because it works doesn't mean it's the best practice or the most efficient way
^
cgrect?
whered u learn that
this is how i would do it
function sortTorrentsByName() {
const getName = node => node.getAttribute("name").toUpperCase().replace(/\./g, ' ');
const torrents = Array.from(document.querySelectorAll("torrent"));
torrents.sort((a, b) => getName(a).localeCompare(getName(b)));
for (let i = 0, torrent = torrents[i]; i < torrents.length; i++) {
torrent.style.order = index;
}
}
prefer standard for loops over forEach because theyre much faster
oh ok
you could even
there
that is faster because youre not allocating a function on each stack frame of the callback to .sort
function sortTorrentsByName() {
const torrents = document.querySelectorAll('torrent');
const sortedTorrents = Array.from(torrents).sort((a, b) => {
const nameA = a.getAttribute("name").toUpperCase().replace(/\./g, ' ');
const nameB = b.getAttribute("name").toUpperCase().replace(/\./g, ' ');
return nameA.localeCompare(nameB);
});
for (const [index, torrent] of sortedTorrents.entries()) {
torrent.style.order = index;
}
}
i don't really use js- assuming that'll do the same thing
didnt know u could do that => thing
arrow functions my beloved
const a = () => {
return 5;
}
``` and
```ts
const a = () => 5;
``` are exactly the same
that is the most cursed way to write a function (the first one)
not really
its just preference if the function body is big
yea thats what i do
ask night for the 16Player SS's 
but those arent actually the same expression
const a = () => {
return 5;
}
is not the same as
function a() {
return 5;
}
no
if you define the first one and try to access this, you will get the this of the arrow function scope
if you define the second one you will not, you will get the this of the parent scope (for example a class's this)
its a lexical scope difference
because anonymous functions dont create a new lexical scope theyre more of a "callback"
i don't trust programming languages that use this instead of self
js 
💀
i need to get a reference of this outside of the arrow function
because i wont have access to it inside of the arrow function
so i need to capture it beforehand to be able to use it
alternatively you can do ```ts
const a = (() => 5).bind(this);
😭
✨ javascript ✨
🎉
yay
now for the rest 
fyi for (i = 0; i < x; i++) loops are faster than for (const a of b) loops which are faster than b.forEach(a) loops
localcompare does numbers right ?
locale = localization = language so no

if you wanna sort by numbers do
myNumberArray.sort((a, b) => a - b) // ascending
myNumberArray.sort((a, b) => b - a) // descending
k
try put 132 in there somewhere
itll insert it between 13 and 21
oh
its sorting them by strings
localeCompare doesnt exist as a method on the Number class
or rather
a better example is this
because theyre already "sorted" in the array i showed in that screenshot
its sort of like sorting "an", "and", and "bat"
would this work ```js
function sortTorrentsByNumAtribute(attribute){
const torrents = document.querySelectorAll('torrent');
const sortedTorrents = Array.from(torrents).sort((a, b) => {
return a.getAttribute("attribute") - b.getAttribute("attribute");
});
for (const [index, torrent] of sortedTorrents.entries()) {
torrent.style.order = index;
torrent.setAttribute("order", index);
}
console.log("sorted Torrrents By ", attribute);
}``` doesnt seam to
🎉
oops
Only true if you are doing over a million permutations.
but list comprehension and enumerate -> index, entry tuple's are super nice to have codewise
i wrote a performance example in the browser and it had significant performance improvements with arrays of length 1e5 or less (even 1e4 has noticeable improvements)
on node its almost exactly the same until 1 million+ permutations, yes
I would argue that readability is more important in this case, especially since its extremely unlikely they would be rendering 1e4 elements to the dom without it being virtualized anyway
lol yeah of course
fyi running a more heavy operation like logging to the screen on an array with more than like 200 elements kills the page due to not enough ram so i cant really test that accurately
with 2e2 elements the results are pretty clear tho
ideally i would run this test about 500 times and average it but it takes quite a while so i wont
const array = new Array(2e2).fill(null).map((_, i) => ({
sayHi() {
console.log(`Hi I am element ${i + 1}/${array.length}`);
}
}));
const forStart = performance.now();
for (let i = 0, element = array[i]; i < array.length; i++) {
element.sayHi();
}
const forEnd = performance.now();
const forEachStart = performance.now();
array.forEach(element => element.sayHi());
const forEachEnd = performance.now();
console.log(`for took ${forEnd - forStart}`);
console.log(`forEach took ${forEachEnd - forEachStart}`);
Im going to ignore that because forEach and map is easier to spell
i added scientific notation to elle because of this snippet lmfao
use std/io;
fn main() {
long a = 0xDEADBEEF;
int b = 0o273451456;
int c = 0b111010011011111010010100101;
long d = 1.2e9;
double e = 2.7182818e0;
printf(
"a = %X\nb = %d\nc = %d\nd = %ld\ne = %.7f\n",
a, b, c, d, e
);
}
it was a pain because i had to handle both ints and floats
cursed ios 15.4> , anyone know how to solve the floating bar issue in css ? insead of using vh i use ?
ig im jus cooked
Oh well (ios 15.1.1)
dvh?
does something like github even load on a webkit version that old
hola, anyone know of a discord for macos/apple dev in general?
If there's a developer here interested in a gig, I'm offering $2k for a custom Tinder Bypass
Requirements:
To work on iPhones 8 and X
Palera1n jb
ios 16.7.8
Has to be able to work with a few tweaks
Do not waste my time, we'll do the deal with a trusted middleman, that we both agree on.
Best regards
https://reddit.com/r/TweakBounty might be interested
Thank you
There is theos discord and hackdifferent discord
I found hack diff, can you dm me about theos?
that’s wild
tweak injection on the latest version of Tinder. What are some of the tweaks that will be used? I’ll demonstrate they work
Token Grabbers, model spoofer, location spoofer and vpn, but last 2 can be done with gerarium and shadowrocket
If you can impletement everything in 1 tweak, budget is unlimited
Token grabber :/
Authtoken, refreshtoken, deviceid and persistentid
it’s so they can login to tinder accounts without a phone
Backend API automation
P.S. apologise for the spam to everyone that has notifications on
yeah
im making a tweak for the twitter app, do i put the twitter bundleID in MobileSubstrate bundle filter option? theos
does the request include implementing that stuff, or is it sufficient to deliver a tweak that allows other tweaks to be loaded into Tinder
yes
ok thanks
Sufficient to deliver a tweak that allows other tweaks to be loaded into Tinder. I'll be on a flight for the next 7 ish hours tho
Me when waydroid:
Tho I’ve got no clue, haven’t had the need for tinder
hepl polos gusy
this is so fucked up
In theory, will it be possible to force it on an older version of the app? As far as I know, the UI for it has been in the app for a long time
So we'd just need a tweak that forces the UI to enable, and it should work once the server accepts the requests
can someone explain in simpler details how logical AND/OR works
i implemented it but it feels a bit inefficient
for AND,
- it declares a temporary with 0
- it checks the left side
- if left side is 0 (false), it jumps to the end, otherwise it jumps to the right side
- if the right side is 0 (false), it jumps to the end, otherwise it jumps to a special label that sets the temporary to 1
- at the special label, it sets the temporary to 1 and then jumps to the end
for OR,
- it declares a temporary with 0
- it checks the left side
- if left side is 0 (false), it jumps to the right side, otherwise it jumps to the special label
- if the right side is 0 (false), it jumps to the end, otherwise it jumps to the special label
- at the special label, it sets the temporary to 1 and then jumps to the end
there has gotta be a simpler way to do that
that sounds about right
however this means that if you do
fn meow() {
puts("meow!");
}
fn main() {
bool a = false;
a && meow();
}
``` `meow` will never be called
likewise if you do
fn meow() {
puts("meow!");
}
fn main() {
int a = true;
a || meow();
}
``` `meow` will never be called
@placid kraken that also sounds right
why should meow() be called here
imo it'd be a bug if it were called
meow will not be called
that sounds correct, that's what i'm saying
isn't that the same as C's behavior?
yes
because for example that temporary can then be used in an if statement which does jnz with that temp
consider this: a == null || !a.flag
you don't want the right side to be evaluated if the left side succeeds
yep makes sense
erm in asm you could just j{ne, le, gt, lt, gt, ...}
but
this is called short circuiting

until now all "logical" expressions were just calling bitwise ones internally lol
now theyre actually logical
magic
no just one of many compiler optimizations
(which might as well be magic yes)
Really useful magic though
@placid kraken also what's the precedence of && and ||
i mean its less of an optimization and more of a logical step
iirc || usually has precedence
pub fn precedence(&self) -> i8 {
match self {
// Self::Exponent => 8,
Self::Multiply | Self::Divide | Self::Modulus => 7,
Self::Add | Self::Subtract => 6,
Self::LessThan | Self::LessThanEqual | Self::GreaterThan | Self::GreaterThanEqual => 5,
Self::EqualTo | Self::NotEqualTo => 4,
Self::And | Self::BitwiseAnd => 3,
Self::BitwiseXor => 2,
Self::Or | Self::BitwiseOr => 1,
_ => 0,
}
}
or maybe i'm wrong idk
no wait it was && yeah
I mean that's literally what compiler optimizations are
logically think through if things can be added/removed/rearranged without side effects
nope
even if i did that it wouldnt really matter due to dead code elimination later
yeah but in this case some assumptions might be incorrect if this optimisation wasnt there
like that example greencraze said
where you wouldnt want something to run if the first part is already true
so without the optimization some things might break
which makes it less of an optimization inherently and more of a compiler step
even though it is an optimization in nature
hm
short circuiting isn't an optimization, it is done even with no optimization in C
yeah
thats probably because its fundamental to the program running without undefined behavior, even though it technically optimizes the code
where UB is used in a slightly different context than usual, just not knowing what result the compiler will produce when you write the code
also does C have different syntax for sar and shr
for what?
for shifting to the right preserving the sign or filling the freed bits with 0s
im gonna assume its always preserving the sign of the value?
considering this returns -32 and 32 respectively idk
int main() {
int a = -64;
a >>= 1;
int b = 64;
b >>= 1;
printf("%d\n%d\n", a, b);
}
then i guess it's always preserving
@placid kraken @radiant idol what do you think
increase the horizontal margin on all of these buttons
the background gets too close to the text on the sides
aswell as like these lol
other than that its pretty goo
d
hmm
its i think a little hard bc like the text box fills the spaces where text could go
not where it is
send css
Congrats, I don’t see a spelling issue
lmfao
Very teslaman-y
how do i not make it teslaman-y
.panelStat{
width: max-content;
height: calc(100% - 22px);
padding: 3px;
margin:2px;
display: flex;
flex-direction: row;
flex-wrap: nowrap;
gap: 5px;
align-items: center;
border: var(--GlassBorder) 1px solid;
border-radius: 10px;
}
.pusher{
margin-right: auto !important;
}
.panelStat img{
width: auto;
height: 100%;
}
.panelStat p{
width: fit-content;
height: 100%;
display: flex;
}```
<div class="panelStat" stat="dl_info_speed">
<img class="svgIcon" src="/img/cloud-download-svgrepo-com.svg" alt="">
<p>0 B/s</p>
</div>```
why dows loging in freez the tab smh
😭
oh it was nothing, nvm
btw they are here to
linux iso's 👍
just one?
add a margin-inline value to your .panelStat p selector
i searched for ubuntu specially *
oh
this is implementation defined and can vary on the compiler you use
i'm blind

wonderful i love UB
just one ubuntu iso?
not UB, just ID
implementation-defined?
implementation defined
yea
yes
don't we all
maybe do like 4px if ur using px
margin is for vertical and horizontal, it sets both at once
average language development
margin-block is for vertical specifically
we are at the cutting edge of language 💪
il jus do this fun ```css
padding: 3px 6px 3px 6px;
oh uk ok
u know u can do padding-left, padding-right etc right
ik but like its less lines yk
and u can also do padding: x y where x is for vertical and y is for horizontal
fric
i hate css, it never does what i want it to
lmao for realsies
thats why i use tailwind
the "cascading" part of css, its main selling point, is the worst part about it
wow these look better to now
tailwind was worse for me cos it was harder to keep track of everything
tailwind's main goal was to eliminate the cascading part of css
and also duplication for the same code everywhere
where you have 25 different classes but theyre all basically just a flexbox
yes.
they didn’t really solve that lol
instead of
<div class="a"></div>
<div class="b"></div>
.a {
display: flex;
}
.b {
display: flex;
}
/* ... */
you just have
<div class="flex"></div>
<div class="flex"></div>
i have sm like that
theyre called "utility classes"
oh
so for example
<button class="bg-red-500 text-white py-2 px-4 rounded-none">
Click me
</button>
Me when I write raw HTML and noe have to copy paste the same classnames to 20 different elements
a button with a red background, white text, 2 padding vertical, 4 padding horizontal, no border
i mean u can jus do that with regular CSS no ?
my.css 💯
yes but its about being able to do that without actually writing css code lmao
tailwind solves many problems its just hard to read with a lot of classes
ok now @wooden yarrow this is the real question
should this
fn main() {
bool a = true;
a && (int b = 5);
}
``` throw an error
its like conditional compilation but runtime
be me, write actual css like it's 2012
huh, why an error
no frameworks, no compilation, just plain css
i think i just need to relearn css entirely but it’s hard to forget what you’ve already learnt
i relearn it every time i use it
what should it do then lmao
which is not often
like should i use pixels or not
just compile normally 
and since this is resolved at compile time
because right now it silently stops compiling anything after the declaration (thats obviously not correct behavior lmfao)
just include
what is this supposed to do
thats the thing
a isnt constexpr
why declare a variable in there
its more for something like this
use std/io;
fn main() {
bool a = true;
int b = 100;
a && (b = 5);
printf("%d\n", b);
}
``` like a shorthand if statement
I mean in your ast tree you should atleast be able to pick up literals no
this seems fine
idk C crashes
but a && (int b = 5) ?
what happens if a is false?
is b set to 0?
is it undefined?
nvm it doesnt what
i feel like it should work
.
it does i was being stupid earlier and not wrapping it in ()
also in c the assignment operator returns the rvalue
i know it does in elle too
Depends
c v0.5 fr
still no structs btw
Ppl us rem units but like idk thoes
wtf
theres arrays!!
@placid kraken will you support unions
the IR has unions so maybe i will lmao
they’re relative to the current font size iirc
Relative em iirc (I forgor what em is)
structs are basically fancy arrays with multiple types anyway
you know what would be better than unions
tagged enums

when compiled structs lose their member names and are just compiled as indexes from a base ptr
i wouldn't call that an array
so
struct Foo {
int a;
long b;
}
compiles to
type :Foo = { w, l }
padding:
also structs can have bit sized ints
so
which you cannot easily get with just casting in and out of arrays
-
allocate memory the size of the array
-
use store instruction for each value at each offset from the base ptr
-
when retrieving, calculate an offset from base ptr and use a load instruction
-
allocate memory the size of the struct
-
use store instruction for each value at each offset from the base ptr
-
when retrieving, calculate an offset from base ptr and use a load instruction
the only difference is youre doing more than just a multiplication to get that offset in structs
true
for now bool is just a typedef for int, true is a typedef for 1 and false is a typedef for 0
i think that's also what C does?
literally just C
yeah
other than just %d
yea same
lmao
anyways I don't think the value for true is defined in C
actually
I think usually it's 255 or 1 though
stdbool.h
stdbool.h has it i think
does that define a value though?
ok i'll just stop typing
or is that just impl defined behavior
An application may undefine and then possibly redefine the macros bool, true, and false.
wtf
oh but ok so if you don't include stdbool.h
then it isnt defined
yeah
There’s the built in _Bool and you can use 1 and 0 ig
i mean but then that's diff i think
$ cat test.c
#include <stdbool.h>
#include <stdio.h>
#undef true
#define true 0
int main() {
if (!true) puts(":troll~1:");
}
$ cc test.c
$ ./a.out
:troll~1:
$
meow
putting this in all of my libraries so i confuse C developers
you should do what this tweet says i think
idk why its f if it returns double but whatever
these also make sense more or less i guess
but still _Bool doesnt follow any of these
barely
recompile the kernel so that reading a file named girl always opens a file with the contents nya~~
pull a windows COM1 but with the name "girl"
true
"guys help why cant i save a file called girl"
lmao
I'm gonna do it
$ git clone --recursive https://github.com/coreutils/coreutils
🎉🥳
why do i need tex to compile coreutils 
i failed to take a screenshot 4 times
$ ./src/cat girl
nyaa~
$ echo test > girl
$ ./src/cat girl
nyaa~
$ rm girl
$ ./src/cat girl
nyaa~
$
@wooden yarrow superior coreutils
🔥
"guys why can't i output girls"

for future reference
diff --git a/src/cat.c b/src/cat.c
index b33faeb35..859d4bf98 100644
--- a/src/cat.c
+++ b/src/cat.c
@@ -671,6 +671,7 @@ main (int argc, char **argv)
if (argind < argc)
infile = argv[argind];
+ bool reading_girl = STREQ (infile, "girl");
bool reading_stdin = STREQ (infile, "-");
if (reading_stdin)
{
@@ -679,6 +680,24 @@ main (int argc, char **argv)
if (file_open_mode & O_BINARY)
xset_binary_mode (STDIN_FILENO, O_BINARY);
}
+ else if (reading_girl)
+ {
+ int fds[2];
+ if (pipe(fds) != 0)
+ {
+ error (0, errno, "%s", quotef (infile));
+ ok = false;
+ continue;
+ }
+ if (write(fds[1], "nyaa~\n", 6) != 6)
+ {
+ error (0, errno, "%s", quotef (infile));
+ ok = false;
+ continue;
+ }
+ close(fds[1]);
+ input_desc = fds[0];
+ }
else
{
input_desc = open (infile, file_open_mode);
also wow patch highlighting in discord looks nice for some reason
@clear iron nice name and pfp
Ty! ^^
You could’ve done this with a bash function
but that's not fun
my first solution involved recompiling the kernel
and i still think that's the best solution
unless you can hook syscalls in the kernel with drivers?
i have no idea
@wooden yarrow real
fn toBool(bool value) {
if value {
return "true";
} else {
return "false";
}
}
bool format specifier

%s is my favourite bool format specifier
? fn toBool(bool value) { return value ? "true : "false"; }
ternaries dont exist in elle yet
wait hold on
toBool implies going to a bool
but this is going to a const char*
so toString?
bluetooth os
lmfao
$ cat test.c
#include <stdbool.h>
#include <stdio.h>
int main() {
bool mybool = true;
printf("check out my cool boolean: %s\n", mybool);
}
$ cc test.c
$ ./a.out
Segmentation fault (core dumped)
$
i love c
not even a warning
ill actually add this to the stdlib
wait
free(long ptr) ??
does the language not have pointers
or how do you use them?
its honestly more annoying when trying to print an int but you put %ld and its just completely incorrect
long stands for null *
what the shit
no in this case long is the memory address space
unrelated but nullptr_t is a thing in c++
wtf
oh, yeah
that's just NULL
but type form

your ass would not survive with near/far pointers
string is a macro for char *

wtf are far pointers
In a segmented architecture computer, a far pointer is a pointer to memory in a specific context, such as a segment selector making it possible to point to addresses outside of the default segment.
Comparison and arithmetic on far pointers is problematic: there can be several different segment-offset address pairs pointing to one physical address.
something something arm64?
wow i was wrong
use std/io;
fn other(int *a, string *str) {
printf("(fn other)\n\ta = %d\n\tstr = %s\n", *a, *str);
*a = 542;
}
fn main() {
int a = 39;
string str = "Hello world!";
other(&a, &str);
printf("(fn main)\n\ta = %d\n", a);
}
wait actually why can you not just have a null type
like void in c
actually yeah
i mean in general a void* in C just means pointer to untyped memory right?
would make more sense than null *
yes
which implies that it is always null
pointer that turns into 0 whatever address it has



