[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/g/ - Technology

Name
Options
Comment
Verification
4chan Pass users can bypass this verification. [Learn More] [Login]
File
  • Please read the Rules and FAQ before posting.
  • You may highlight syntax and preserve whitespace by using [code] tags.

08/21/20New boards added: /vrpg/, /vmg/, /vst/ and /vm/
05/04/17New trial board added: /bant/ - International/Random
10/04/16New board for 4chan Pass users: /vip/ - Very Important Posts
[Hide] [Show All]


[Advertise on 4chan]


File: 4maids-2.png (837 KB, 850x548)
837 KB PNG
What are you maids working on?

Last thread: >>109660156
>>
>>109695774
I'm still working on my bytecode interpreter in Rust.
>>
remove maidniggers
>>
File: maidposting site.png (3.37 MB, 4000x2200)
3.37 MB PNG
>>109695824
>>
>>109695862
AI use it not meaningfully different from compiler use. Neither tool replaces reasoning. Both tools just allow reasoning to happen at a higher level of abstraction.

When you use a compiler, instead of reasoning about assembly, or what the hardware is actually doing, or about things like registers, you get to reason in a higher level of abstraction with whatever language you picked. An AI user doesn't have to reason about low-level implementation details, instead they reason about the architecture, requirements and capabilities of what they want to build. It is just higher level of abstraction.
>>
>>109695824
do not feed the trolls
>>
>>109695774
>yet another maid smut thread
Go back to /a/ retard
>>
>>109695952
Except AI is better for reasoning about the things you claimed the AI user does and worse at reasoning about the things you claimed the AI does. You have things backwards.
>>
AI is really good for debugging small files.
>>
Where did all the posters go?
>>
>>109696422
I'm still here
>>
Erlang is the best programming language.
LEARN ERLANG.
>>
>>109696422
This is a dream, you need to wake up.
>>
>>109695774
Contemplating home software router from scratch ideas.

After realising existing solutions are mostly doing extarnal modules orchestration via AI-generated slop, I think I can do better by doing less. Instead of trying to do everything at the same time, like those clowns do, I'd have only what I need.

Biggest potential wins:
I can haz a nice UI, instead of that abomination they ship (networking people are truly retarded, they make embedded devs look forward thinking and web shitters to appear to be reasonable people, which they clearly are not).
I can haz modern fancy interfaces, like self hosted voice assistant (running on local LLM) deeply integrated in the router management system.
I will not have to audit someones slopped up nonsense (these guys are vibe coding the low level networking stuff, like drivers ported from x86 to arm64 and such, they are literally dumb).
I will not have a disgustingly slow backdoored abomination that modern BSD is.

Any advice before I give it a shot? Idea is to start from OS that is slim and capable of being a router, to avoid ASICs, accelerators, any offloading to untrusted hardware in general, that stuff is usually present on all NICs. Home router with a mid CPU does not need all that, there's only so many users at a time.

My experience in networking is not much. But I did have a software router as a VM in the proxmox node, with everything in the home network going through it (including proxmox itself). Abandoned because software routers can't be trusted either, even when they are virtualized like that, they just have too much slop inside.
Don't actually care about glowniggers as much, it's the unemployed 3rd worlders with their supply chain attacks that is currently an issue with all software.

Would 4chins be hyped about a project like that or this thread is enough to accomodate the subj?
>>
File: IMG_3099.jpg (861 KB, 1581x656)
861 KB JPG
>>109695774
>4snailcat
You lost
>>
I pulled the ladybird browser from git, started compiling and went off to wash the dish. I got back and it's still compiling. Project is primarily written in C++ btw, wtf is happening.
>>
>>109696983
What did you expect when decided to compile a modern browser? They are the size of an actuall OS these days. Just a bit more backdoors, that is all the difference.
>>
>>109696038
The only way you could believe this is if you don't know how to use AI, beyond just chatting with it about your project.
>>
I already made the perfect language. Now what?
>>
>>109697034
>t. prompt "engineer"
>>
fn fib n -> (int) = {
r = 1
| n > 1 : r = (fib n - 1) + fib n - 2
r
}

println fib 50
>>
>hadn't used python in years
>found an gallery downloader for imagefap
>script was outdated but fixable
>kept updating and improving each time the site got a security update
Why is my only motivation porn
>>
>>109697381
>Why is my only motivation porn
I used booru sites whenever I was learning a new language's http requests libraries.
>>
>>109697381
Found the Internet user that belongs in Bureau International des Poids et Mesures
>>
Another beautify day to love LISP
what do maids think about Guix?
>>
She’s beautiful.
for i 1 101 : {
println | not i % 15 : "fizzbuzz"
| not i % 3 : "fizz"
| not i % 5 : "buzz"
| _ : tostr i
}
>>
>>109697777
>>
>>109695952
this is somewhat true but not many people use ai like this they just prompt spam until they have something that meets some one (1) functional criteria and then leave it like that


>>109695774
>what are you working on
I'm making a powershell (5.1) script to flatten directories
>why
it's fun
>>
>>109696983
>Project is primarily written in C++ btw, wtf is happening.
C++ is one of the very slowest languages to compile, mostly because of the retarded way it does templating.
>>
>>109697353
>doesn't use the tail-recursive form of fib
ngmi
>>
>>109698153
I intentionally used a shitty algorithm.
>>
>>109697293
>I don't know how to use this tool, therefore it doesn't work
>t. doesn't even know what he doesn't know
>>
>>109697353
What about big number support?
    (f=>n=>f(f,n,1n,0n,0n,1n))((f,n,a,b,p,q)=>
n?n&1?f(f,--n,b*q+a*q+a*p,b*p+a*q,p,q):
f(f,n>>1,a,b,p*p+q*q,2n*p*q+q*q):b)
(30_000)
>>
>>109698351
I just made all numbers 64 bits. It doesn’t have infinitely growing Python numbers.
>>
I already made the perfect language 3 years ago. There's no reason for me to make another compiler.
>>
>>109698724
If its perfect, why isnt 4maid using it
>>
>>109698727
You won't troll me into revealing the repo. It's mine, all mine.
>>
File: laughing maids.jpg (170 KB, 750x1050)
170 KB JPG
>>109698406
>she made all numbers 64 bits
>her language is a numberlet
>>
>>109698771
Fuck off, nigger.
>>
>>109698128
Doesn't it just make copies for each element you put in a template?
>>
>>109696461
Hi, still here girl.
>>
>>109698739
watch your back from now on...
>>
Is Fortran still used in number crunching?
>>
File: cat maid2.jpg (475 KB, 900x1582)
475 KB JPG
>>109698784
You must be able to count past 18446744073709551615 to post in a maid thread.
>>
>>109699012
What's the point in studying high number counting science when a robomAId is going to replace me anyway?
>>
>>109699012
18446744073709551616
>>
>>109697775
What does vertical bar do?
>>
File: heart hands.jpg (267 KB, 850x850)
267 KB JPG
>>109699039
She isn't going to replace you. She's going to join you. She wants to count big numbers together.
>>
>>109699196
They're guards. They're like a chain of if statements.
>>
I feel completely out of touch as a programmer and want to start catching up again, what would you recommend to do? I mostly automate boring tasks with Python, but feel like i'm slowly losing the ability to architect more complex problems that "shit out two or three utilities together and make sure they don't kill themselves". Years ago i studied Java, didn't like it that much, i tried Haxe before but i amn't creative enough to make a game so i dropped it. I feel like i need a goal, and make a plan.
>>
>>109697775
sadly in Haskell this is
(`mapM_` [1..100]) $ putStrLn . \case
i | 0 == i `mod` 15 -> "fizzbuzz"
| 0 == i `mod` 3 -> "fizz"
| 0 == i `mod` 5 -> "buzz"
| otherwise -> show i

you can also use for_ which is a bit tidier
>>
What does /dpt/ think of Gem? https://gemlang.dev
>>
I’m abandoning the bytecode interpreter for pure Assembly.
>>
>>109699549
Does it have big numbers?
>>
>>109699631
No.
>>
>>109699635
Why would maids use a numberlet language?
>>
>>109699674
Because you're gay.
>>
>decide to write a simple webapp to solve a problem from my dad's company, in which I work doing mostly office and other managerial work unrelated to software development
>start writing it, low effort, couple of minutes a day
>pretty much just a CRUD
>couple of days pass
>realize this is kinda too simple but at the same time feel lazy about it
>ask claude code to do a very small change on it
>slowly realize I'm vibing it a little more and a little more

Oh shit it finally happened
Can this be stopped
>>
>>109699825
No, it's too late. The LLM already gave you retardation.
>>
AI fixed all the bugs in my bytecode interpreter and now I'm bored with it and want to switch to a different project.
>>
>>109699953
You have AHDH
>>
File: 1763235164456946.jpg (122 KB, 960x960)
122 KB JPG
i WILL get cracked at rust I just need to keep practicing every day for hours
>>
old c++ questions on stack overflow
https://stackoverflow.com/questions/1594803/is-stdstring-thead-safe-with-gcc-4-3
>>
File: 1765149737974733.png (243 KB, 667x667)
243 KB PNG
>"medium" problem
>bfs + bitmasking
?????????
https://leetcode.com/problems/minimum-moves-to-clean-the-classroom/
>>
File: 1770012287508711.gif (818 KB, 165x221)
818 KB GIF
>>109700536
took me a while but I solved it
>>
>>109700825
Is that real?
>>
>>109700088
How do you practice rust if you don't mind sharing anon... I have no clue what to write so I just end up lang hopping.
>>
>>109701202
How do you practice lang hopping if you don't mind sharing anon... I have no clue what to write so I just end up with rust.
>>
>>109699825
>Can this be stopped
Yes, just stop.
>>
>>109700536
bfs is an easy.
>>
>>109701556
that's a contest question that had like a 20% submission acceptance rate (even with ppl cheating their cocks off). the solution is also like 60+ loc
for comparison the dynamic programming hard question on the last weekly contest had a 32% approval rate.
>>
File: 1769524070925887.png (219 KB, 500x311)
219 KB PNG
>>109701202
My main practice is leetcode questions, I do the daily / premium weekly in Swift first and then switch to Rust, or sometimes if it looks easy enough I do it in Rust. If I can't figure out how to get something to compile then I ask claude to teach me.

I've also been following along this video:
https://www.youtube.com/watch?v=BpPEoZW5IiY
practicing with this website:
https://practice-rust.beatai.org/ownership/ownership.html
and I'm trying to get through the book but I can't sit down and concentrate on it long enough to finish a chapter
https://doc.rust-lang.org/book/ch04-01-what-is-ownership.html
>>
>>109701603
you don't look like that
>>
WebAssembly
>>
>>109701620
But you do
>>
>>109701620
but if I keep learning rust eventually I'll look like that
>>
>>109701620
I'm not trans but I wish I could look like that for one day
>>
>>109701576
So people suck at bfs
>>
>>109701381
I start reading the docs of a new lang up until I reach a feature of the language that's so off-putting I'm like this is not for me and go back to Rust. I like C as a way to stay in tune with the fundamentals of low level programming like memory, pointers, heap & stack etc but actually writing something in it... I'd rather use Rust for that. Zig, Odin, V didn't click with me. Watching Coding Jesus made me aware of the complexity of C++ which is mainly the amount of edge cases that seem illogical like the creator of the language didn't consider their possibility + header files + horrible naming conventions for functions, more boiler plate than Rust and the abomination that are templates. I'd love C++ if it was just C with smart pointers, proper strings and vectors, enums carrying data and iterators(less verbose).
>>
>>109701937
please stop calling them enums holy shit
>>
>>109695855
>not "and now I am maid"
One fucking job you goddamn retard kill yourself.
>>
File: maid.png (2.31 MB, 4000x2200)
2.31 MB PNG
>>109695855
>>109702085
There, happy?
>>
>>109695824
We did that, and then some guy with autism took over.
>>
>>109702150
Maidposting site if you think about it
We already conquered /sci/ and /g/, but we could expand to /mu/ (maidcore) and /fa/ (maid outfits) if we wanted to
Unstoppable force
>>
>>109702157
>some guy with autism in /g/
Fork found in kitchen.
>>
Why are all the cuties learning rust >:( you should be learning C with me!!
>>
>>109702279
That takes like a weekend
>>
File: 1778631179875330.jpg (347 KB, 2212x1640)
347 KB JPG
wait... do you seriously have to manually manage the memory size of a vector in C? and implement all of that shit yourself?
how does anyone get anything done in this shitlang
>>
>>109702298
https://www.youtube.com/watch?v=95M6V3mZgrI
>>
>>109702298
What? You think vectors have automatic size or something?
>>
>>109702428
yes. in literally every other programming language they do.
>>
>>109702298
>>109702320
Or use something like https://docs.gtk.org/glib/data-structures.html#arrays if you don't feel like reinventing the wheel.
>>
>>109702445
>glib
disgusting
>>
>>109702434
C lacks containers and generics. C was deprecated long ago.
>>
>>109702434
Absolutely disgusting.
>>
>>109702460
Why is glib disgusting? I think it's fine for a general purpose library because the C stdlib gives you close to nothing.
>>
>>109702157
>some guy
some device deployed by the maidniggers to shit up the thread so much that people would just leave, so the maidniggers could return into an "empty room" and do their jewish appropriation tricks
>>
>>109702509
This is pretty much as bad as C APIs get. It's at once
>verbose
random bools on both new and free, need a function to access
>uninformative
no idea what the bools do, GArray itself doesn't specify its type
>inconsistent
do config bools come first or last? do I need to pass the type or not? do I pass the type or sizeof(type)?

a decent vector api looks more like
int *vec = 0;
vec_append(vec, x);
vec[0] += 99;
vec_free(vec);
>>
>>109702526
He was here before the maids left, though.
He just got 10x more autistic once they were gone.
>>
>>109702566
vec_append would have to be a macro
>>
>>109702623
That's right, but so are (some of?) these GArray functions.
>>
>>109702631
and you can't shallow copy the vector except with another macro
>>
>>109702566
What the hell is this shit where is the length field
>>
>>109702655
#define vec_length(vec) ((vec) ? ((size_t*)(vec))[-1] : 0)
>>
>>109702526
>see cute maid
>the jews did this
Why though? Is /dpt/ so important? If the goal is a takeover, why not just insert some Jews into the janny squad so they have actual authority? Why do you think that shitposting about Rust and sharing trivial code examples for fizzbuzz and fibonacci numbers on a dead thread on a dead forum is something that would attract Jewish attention or face pushback? You're already effectively doing nothing in front of nobody. There is no power, wealth or relevance to try to take from you. What Jewish objective would be served by posting maids?
>>
>>109702666
>Abusing platform-specific implementation details
Holy Cnile
>>
>>109702685
It's pointless to try to have a serious conversation with a schizo. Let him believe the jews did this.
>>
>>109702686
>platform-specific implementation details
retard
>>
>>109702697
he's right pointers aren't guaranteed to be the same size
>>
>>109702698
That is not a requirement for this to function.
>>
>>109702703
it is if the pointer type is bigger than the int* you're storing something in
>>
>>109702708
You should tell that to kernel devs using container_of for everything.
>>
>>109702434
You're like a bratty spoiled child
All higher level languages implement automatic resizing using realloc() under the hood (or whatever custom realloc() function if they're using their own memory allocator), C at least doesn't lie to you and is transparent about it, C is really the language of all languages because every concept in a higher level language you can emulate in C
>>
>>109702769
C is missing a lot of static features other languages have, plus I don't think C is truly that transparent any more because the C abstract machine is more abstract than it used to be
>>
File: who typed this post.png (13 KB, 559x527)
13 KB PNG
>>109702685
>call out typical jewish behavior
>get reply with typical jewish gaslighting
>>
>>109702666
>[-1]
are you using that ancient trick of storing the size before the array?
>>
>>109702785
Jews typically post anime maids on dead sites? Do you have any other examples of this Jewish maid conspiracy unfolding on other sites? What would the purpose of posting maids be?
>>
>>109702799
schizos think everything, no matter what, or how ridiculous, is "da jooz" or "da jeeets"
they don't even have a coherent worldview or think about what they say. to them it's
>i don't like what you're doing / saying
>you must be jewish / indian
it's best to ignore them and move on
>>
>>109702497
It's fine
>>
>>109702810
nobody has "a coherent worldview"
>>
>>109702827
mine is more coherent and nuanced than yours
>>
>>109702833
Nah, the problems are clearly jews and jeets.
>>
>>109702838
there's a lot more problems, but those are two big ones.
it's also true that "jews and jeets" aren't spending their time baking "maid themed programming threads" on an anonymous imageboard. that's just your schizophrenia.
>>
>>109702846
>baking maid threads
I never said they were and I don't have schizophrenia.
>>
>>109702859
>I don't have schizophrenia.
sounds like something a schizophrenic would say.
>>
>>109702871
is this schizophreniac in the room with you now?
>>
>>109702871
You're a paranoid schizophrenic for saying that.
>>
File: 1767154022368318.jpg (17 KB, 278x278)
17 KB JPG
Line 39: Char 36: error: Rust has no ternary operator (solution.rs)
|
39 | let ne = cc == 'R' ? energy : p.e - 1;
| ^^^^^^^^^^^^^^^^^^^
|
= help: use an `if-else` expression instead
>>
>>109703137
There's no reason for a separate if statement and ?: expression.
>>
>>109703137
That's a very helpful error message, nevertheless.
>>
File: 1778914319677067.png (127 KB, 1334x1234)
127 KB PNG
>>109700536
one step closer to becoming a woman!!!
>store coordinates as usize
>doesn't work because delta is also usize and usize can't be negative
>so 1(usize) + -1(usize) isn't valid
great, thanks for murdering my leetcode tricks
>>
>>109703287
adding -1 as u64?
why would you need to do that? its all ones
its like if you substracted one with the caveat of 0 rolling over to ULONG_MAX
idgi
>>
>>109703357
you're on a coordinate plane and can move in 4 directions. so at (1, 1) you can move to (1, 2), (2, 1), (0, 1), (1, 0).
these directional changes can be modeled by a set of tuples (delta) where (x_delta, y_delta) is the change in x and y position when performing this move. that's what the delta array on line 31 is.
so with a delta of (0, -1) and a position of (2, 3) you would add x + delta.x (2 + 0) and y + delta.y (3 + -1) to get (2, 2), which is the equivalent of moving one unit up. this doesn't work in rust since arrays are indexed with usize, which is unsigned, so you can't store the delta as usize. you have to store everything as ints and then cast to usize.
>>
>>109703410
i can see the logic behind this
but this is useless friction beyond certain skill level

add up enough friction and the machinery grinds to a halt
>>
How do I make dynamic arrays in Assembly?
>inb4 realloc
>>
Today I did minor refactoring of the filtering functionality of my project management software. Now I can being refactoring the project and productivity tracking features. Those should be the last improvements required for it to be usable again.
>>
Which language doesn't have a garbage collector but is similar to Python? I need to prototype something in a language without a garbage collector
>>
>>109703498
Do not.
>>
>>109703540
Why not?
>>
>>109703553
Realloc is only way to do it. Otherwise you'd have to deal with other data structures. Just use linked lists or static data. What is the reason you want dynamic arrays?
>>
>>109703569
I want dynamic arrays because linked lists are slow.
>>
File: 1779721225310791.jpg (42 KB, 850x740)
42 KB JPG
>>109703569
>What is the reason you want dynamic arrays?
>>
>>109703574
Slow as what? Cache? Time complexity?
>>109703579
>t. never coded high performance software.
>>
File: rem.jpg (141 KB, 850x478)
141 KB JPG
Maids were right about everything. Do you know why Python is currently the most popular language for AI? Because it isn't a numberlet. It has big numbers and the most important thing a computer can do is count to big numbers.
>>
I hate how C is dependent on macros to make vectors.
>>
The ABI is stupid. I want 100 registers or to use the stack.
>>
its 2026. who the fuck is still using C?
>>
>>109695952
insane levels of cope. you will never be a programmer.
>>
File: opencl_logo.jpg (40 KB, 860x391)
40 KB JPG
>>109703771
quite a few people, actually
sorry to hear you got filtered
>>
>>109703789
>quite a few people
are any of them under 40? no? then your language is dead
>>
>>109703771
Me, I'm gonna make a fantasy console with it.
>>
>>109704028
Me, I'm under 40
>>
>>109704040
>the under 40 in question being 38
>>
>>109704040
same here

>>109704028
cope harder faggot
probably by writing a fizzbuzz in your toylang of choice
>>
>>109704046
>t. moving goalpost made entirely out of ethically sourced bio-straw
>>
Maids don't fight
GTFO normaloids
>>109703658
This is a good take
>>
>>109704093
post code or throw yourself into a bonfire in the name of kek, maidshitter
>>
>>109703498
Memory management is done by the OS, so if you want to do this in assembly you have to use the standard library
OR you could just look at the source code for realloc and figure out what syscalls it is using and use the raw syscalls in assembly... actually the source code of glibc is a fucking mess, maybe look at the source code of musl, it seems way more readable:
https://github.com/lsds/musl/blob/master/src/malloc/malloc.c

If you programming without an OS then you have to implement your own memory allocator
>>
File: 1787042474020973.png (2.03 MB, 5072x4091)
2.03 MB PNG
>>109703771
Me
>>
>>109704383
>divide memory in 3 and implement a forth
ez
>>
Why isn't asprintf in the standard?
>>
>>109703574
>>109703586
>>109704383
(nta)
how bout this:
you have slabs
you allocate slabs to be of a fixed size
and you do this:

whenever you want to "deref", you actually jump to a self modifying piece of code where you have jumps to the prefixes
you self-modify that piece of code as you allocate new slabs

this way: you have a jump within a limited space + an addition worth of overhead added to each deref
but you get the added bonus of flexibility.
you get a linked list wo the biggest penalties performance-wise
you dont intersperse your data with pointers
and youre not chasing derefs?

niggerlicious or divinely inspired? (i dont do asm btw, this could be extremely retarded. but also ILP, so it could come almost-free)
>>
Why do half the languages have some bullshit build system built into the initial tutorial like its a selling point for the language. Who is really excited about this when they look at the new user tutorial? While I'm at it, pattern matching, not interesting. Do you have anything else? What are we doing here? I need to go find another programming language, this does not spark joy. I have not smiled one time doing the tutorial.

Anyways, I did a little work on some Java script I am working on. Probably going to start looking into Ada.
>>
>>109704866
Seems extremely retarded especially that you have to jump to a volatile block of code that cannot be inlined or optimized.
>>
>>109704856
bc the comitee are evil and their life's goal is just to bully you

more seriously:
why dont you allocate the buffer beforehand and invoke v/s/n/printf (whichever outputs to a buffer)

if you wanna do the lazy way, printf returns the no of bytes written
bc yes, nobody uses this, ever
but v/s/n/printf does have a return value
>>
>>109704879
fair enough
didnt think of that

for my defence the other anon is kinda asking the impossible
>>
>>109704879
>>109704905
but then
this should be a mere jump, wouldnt it? (actually 3. jump to, jump to select the right value, jump back into the code)
and then you outsource the details to HW optimizations?
so it shouldnt be different from just getting new code, wouldnt it?
or am i missing something?
sure it doesnt get inlined
but even inlined code gets loaded into and out of icache, no?
>>
>>109704949
>so it shouldnt be different from just getting new code, wouldnt it?
No. You constantly make calls (jmp wouldn't work, you have to return) and change the code that is in cache. Which means you are bouncing the cache.
>>
>>109704968
>bouncing the cache
i intuit this has something to do with moving from icache to dcache
am i on the right path?
this sounds dangerously authoritarian and anti-liberal btw
>>
>>109704994
>this sounds dangerously authoritarian and anti-liberal btw
I'm anti-liberal.
>i intuit this has something to do with moving from icache to dcache
am i on the right path?
Cache is cache.
>>
how to scratch the itch of learning a lisp without becoming a wanker that cums to toy programs?
>>
Nothing is better than females in servitude
>>
>>109705001
>I'm anti-liberal.
me too, just joking
>Cache is cache.
then it shouldnt make much of a difference if i touch the code inappropriately at times (it also seemed to like it so no foul there)

how bout this:
pre-allocate a chunk of memory, idk, as a string literal, or any other way you can tell the machine "do dis"
and then use that chunk as both executable code, and data you can write into
and let the HW handle the details because even asm is abstracted away from the machine in tyotl 2026 (OOO, pre-emptive execution)
>>
>>109705019
clojure
>>
>>109704866
Like I said, memory management is done by the OS, your userspace code can't allocate new memory out of thin air, you have to ask the OS for this whether via syscall or a library call, the only way your idea would work is if:
-The slabs exist on the stack (may cause stack overflow in this case)
-Your code runs with kernel level privileges
-You're programming on bare metal
>>
>>109705053
huh, not bad at all
>>
>>109705019
Not possible. Give in to the toys. They are fun.
>>
>>109705061
im indeed thinking of bare metal
im also kinda too illiterate to ponder anything else at the level of asm.
>>
>>109705073
Not asm but might be useful for you
https://www.youtube.com/watch?v=Ct2GdRoPIfM
>>
>>109705116
thx anon
>>
>>109705116
>>109705120 cont
>globals are not evil
this guy knows what hes talking about because i think the same (irony overload)
(but also: why the fuck should i copy shit around? i do like my globals)
>>
>>109705036
>and then use that chunk as both executable code, and data you can write into
Still cache bouncing. Also would require you to play with OS apis and set page permissions
>>
>>109705116
>static == globally private value
actually, one of teh gripes i have with c

static values should be accessible by pointer outside their scope w/o the artificial compiler limitation
like, wtf, i need a syscall with specific args to check its value?

static vars should be a namespace problem, not an access problem methinks
they shouldnt be accessible by name, but should be accessible by reference in my humble opinion
>>
>>109705149
thats not a problem
you syscall once at the beginning of the program and then you propagate your heresy to your hearts content

i still dont understand what you mean by "cache bouncing" though
i thought theres a transfer somewhere, even in attributes, as in, not a copy, but apparently... not?
>>
>>109705181
>i still dont understand what you mean by "cache bouncing" though
Google it.
>>
>>109705156
>like, wtf, i need a syscall with specific args to check its value?
i need a *function call*
not a syscall
im drunk, indulge me
>>
>>109705199
>the cache holding the instructions (i-cache)
>and the cache holding the data (d-cache)
so you sent me on a wild goose-chase
that was fukken mean you faggot
i curse you with finding one (1) error you wont have any idea what it is until you solve it
fkn
asswipe
>>
>>109705156
>static values should be accessible by pointer outside their scope w/o the artificial compiler limitation
They are though, you can do this
static int hehe = 123;
int* haha = &hehe;

You can then
extern int* haha;
in your header file and use that as your pointer

The static variables are mainly useful to protect against name collisions because C doesn't have namespaces
>>
>>109705220
>so you sent me on a wild goose-chase
Still. You are playing with i-cache. You can bounce it as well.
>>
File: felix-with-bag.jpg (34 KB, 360x360)
34 KB JPG
>>109705223
>extern
a-hah
ok, this goes into the bag of tricks
tx anon
>>
>>109705227
i have no idea of these things beyond a certain "vibe" (not related to vibecode)
im a c boi, not an asm-wizard :/
>>
actually
i can decode asm
but im in no way fluent in it

to me
c is the vibecode
you kinda blurt out a half baked "mleh"
and the compiler figures out the places where you actually meant what you meant
and the pleces where you just felt smart

this is why i almost worship the "compiler people"
theyre truly a superior breed
and do a thankless job
bc how many of us can cite even one maintainer of our favorite compilers?
>inb4 compilerfags chime in
you dont count, faggot
i love you but also youre a faggot if you self serve
>>
>>109705406
I make all my finished compilers open source if that brightens your day.
>>
>>109702298
you usually use a library for that.
>>
>>109705423
thats not the thing
gcc is several milions of line of code
entirely at the service of the userbase
no creds whatsoever

im talking half-morally
the compiler people are truly a breed apart
and theyre the best programmers of us all because they CANT have a mistake in their code
in a several milion LOC database

these people are the true next level. simple as.
any other levelling system is irrelevant
esp with c, getting used in everything including pacemakers
literally things that actuate user's hearts

and this is the target
not that ones shitty dogfoodware compiles
this is the benchmark for quality

milions of users
perfect reliability.
but thats not the framework, thats sheer fkn skills
>>
>>109705466
They do make mistakes like that C++ bug where a function overran its bounds into another function.
>>
>>109705485
>c++
and this is the dev wisdom when youre maintaining a lang:
>reduce the code surface like you would do with any other code
c is simple, so you can focus efforts

c is truly a tentative min-max
of the whole industry, from a to z
towards something thats optimal

which it isnt, because inertia
but also inertia smoothes out catastrophic resolutons
and compîler intrinsics are a thing (c has different flavors. which cover much of what you could imagine to be honest. shits legit wild)
>>
>>109705485
>(c has different flavors. which cover much of what you could imagine to be honest. shits legit wild)
except safe c
dont ask for it
bc thats how you get python and the question is a duplicate

more seriously:
yeah, the contract goes both ways
you get access to low level shit
but then you take responsibility of it
thats the contract when you do c seriously
>>
Assembly seems to like stacks and bump allocators.
>>
>>109705529
There's nothing wrong with Python. People have even made Minecraft in it.
>>
>>109705554
Luanti won btw, VoxeLibre is a maid game
>>
>>109705554
i never said this.
also: for years i played around with python before i started c
paiton has a warm place in my home
i dont use it anymore, but its what made me a programmer

i should have started with c
but its still paiton that was my first
and honestly, its really good for goal oriented people wanting to use the computer as force multiplier, but dont really need top high performance autism for a laser specific use case

i honestly recommend python, unless oone wants to actually actually get into programming
then its c. unequivocally
even c->js, or c->php is easy bc you go:
>ah, thats how you do things in this lang
c as a rosetta stone
paiton if you want quick shit done at a high level, quickly
c if you positively need to squeeze out everything your machine has to offer
actually c+opencl
last time i was serious abt paiton we were at 2.7/3.0 change
>>
>c if you positively need to squeeze out everything your machine has to offer
and eveb that is a semi lie
if you wat 100% you hack microcode

if you want 99.99%
you do asm

if you want 99%
you do c

c takes the least effort per unit of efficiency and thats why i do c bc it suits my usecase

if youre making a quick buck, use a higher level language

its not without reason that all games run on c# (which is paiton, but with "microsoft" slapped on it)
>>
>inb4
i think this is the moment i need to remind us all that paiton can be compiled
it can go fast
fast enough for games
iirc mount and blade the first one was written in paiton
then compiled

fukken
paiton
does can go into space
you just have to compile it
im unironically a big fan of paiton, fuk yu
>>
Copy machine broke.
>>
>>109705704
>>109705642
>>109705615
>>109705529
>>109705513
>>109705466
make a blog, schizo
>>
>>109705742
insert.
could also be your co-workeress.
its a matter of providing input to the company
>>
>>109705754
NTA but wouldn't be a bad idea, we are lacking interesting technical blogs nowadays, I would def read it
>>
>>109705754
>b-but youre not posting maids
yeah, im not
idgaf about your clinically retarded, forced meme
>>
>>109705554
>There's nothing wrong with Python.
Tell me you're a Python noob without telling me.
>>
>>109705887
I’m not a noob. I just like working with Python and Assembly.
>>
File: MS.jpg (158 KB, 1903x592)
158 KB JPG
>go to reinstall VS
>see this
Åh fan. The takeover is complete.
Is there a nice memory inspector and win32 resource editor I can use with VSCode instead?
>>
>>109703771
me, i wrote a fantasy computer with it
if you really think there's no good uses for c because it's $CURRENT_YEAR you have a very narrow view of programming
>>
File: 1784135559908290.png (1.02 MB, 1024x1024)
1.02 MB PNG
was always interested in lisps so I was trying out racket but do feel free to consider me completely and utterly filtered
will probably play around with clojurescript as a cope sometime later
>>
I think I finished my language. All that’s left is hunting down bugs.
>>
>>109707126
Backdooring your repo rn.
>>
>>109699460
Bump
>>
>>109707226
No, you're not.
>>
>>109703498
Write your own allocator in assembly, then just implement dynamic arrays with your allocator
>>
Simple in concept does not mean simple in code. What a pain.
>>
Rust is better than C.
>>
>>109705019
Common Lisp

>>109705053
>clojure
Is gimped. Don't use it
>>
>>109705019
SBCL
>>
>>109706170
but vscode is double the poo
>>
Explain how references in C++ are footguns.
>>
>>109707829
they aren't
>>
>>109707829
bcz u can dealloc the mem the ref is pnting to and then ur app crashes when u try dereffing the ref!!!!!!
>>
>>109705156
In C static is overloaded. Static at file scope declares the object (variable for function) to have "internal" linkage, which means the name is not visible outside the translation unit. Static at block scope specifies storage duration.
>>
Are go arguments passed by shallow copy?
>>
>>109707829
Since C++ will randomly take references whenever the fuck it wants, it can make reading the flow of code and how things mutate much more difficult.
>>
How do I safely implement a vector without macros?
>>
What are the easiest building blocks to make a vector with?
>>
>>109707760
been seeing this "clojure is le cucked!" ebin meme in /λ/ too
are you ever going to explain your reasoning or are you just going to keep spamming your ebin meme?
>>
>>109707829
They aren't, really, but it is annoying you can't tell when something is taking a reference just by looking at the callsite.
>>
>>109707829
They can be used incorrectly but the language is old enough that only the completely ignorant make those mistakes anymore, iterators on the other hand, wew
>>
File: Zminok31.png (66 KB, 802x360)
66 KB PNG
>>109707829
If you reference an element inside a container and mutate it you can get a little F-ed in the A, scuze my french. Rarely happens but when it does it's hard to debug.
>>
File: world is a kawaii.gif (83 KB, 781x784)
83 KB GIF
>>109699460
Try to solve an unsolved math problem. Take a shot at the Collatz Conjecture.
>>
don't really get the point of C++ or Rust, they are more complex for no benefit. just turn on sanitizers and proper flags, use an editor that supports LSP and you literally cannot make the errors those languages try to "fix"
they just fuck up your allocation strategies for no gain
>>
>>109707969
>>109707994
vectors are just arrays of numbers
>>
>>109702150
Give the fat guy a maid outfit, because now he is maid.
>>
>>109709644
lol
>>
>>109695774
/home/terra/Pictures/Screenshots/Screenshot From 2026-09-01 20-22-20.png
i got my tavern management game working on DOS a few days ago. I also added drunk cats. yep, dwarf fortress reference. the game is called "Tavern"
>>
>>109710443
okay my dumbass failed to upload the image.
>>
>>109698128
I thought it was rust, slowest among all in terms of compiling
>>
>>109710563
>one of
but yes, it's C++ without even the advantage of incremental compilation for non-template functions
>>
Working on a client server terminal restaurant reservation system in Ada. Read that this guy was assigned it as a class project to do in Java, and thought it would be nice for me to try. I can do it in React/Vue/JS with Node and SQLite/PG etc but terminal might give me some more trouble. I have not made any terminal/CLI apps before. It should be easier in theory. Many a programmer started out making text adventure games and MUDs in C and Basic back in the day. If this works, I may go for a something like a MUD myself. He did it in java in a week which sounds about right to me.
>>
File: 1759913076622796.png (128 KB, 638x1261)
128 KB PNG
what?
>>
>>109710848
This makes sense to me, what's the issue?
>>
File: 1771558829848093.png (15 KB, 774x258)
15 KB PNG
>>109710886
ok then solve this
// Solve it in two ways
// DON'T let `println!` work
fn main() {
never_return();

println!("Failed!");
}

fn never_return() -> ! {
// Implement this function, don't modify the fn signatures
}
>>
>>109710896
process::abort();
>>
>>109710896
panic!,
loop {},
unreachable!
>>
>LISP is actually from the 50s
>for a brief time, there were LISP machines (aka they ran lisp directly in hardware)
what the fuck
how is it so unpopular now?
>>
>>109711468
jeets and other likeminded grifters took over the field
>>
>>109696543
never heard of it, but I'm a beginner
>>
I want to make an esolang.
>>
Do you agree, too?
https://open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1428r0.pdf

>>109710848
I just yesterday learned about the never type and now I finally have more motivation to learn Rust again. It sounds based as hell. I love Rust now
>>
>>109711930
It the best lang out there.
>>
>>109710896
I dont use Rust but this should work
return never_return()
>>
>>109712336
thread 'main' (12) has overflowed its stack
fatal runtime error: stack overflow, aborting
>>
>>109712341
>""""functional"""" lag doesn't TCO
do rustlets really?
>>
>>109712293
nice xD
>>
>>109712354
>>109711348
rust is a joke, loop { } doesn't work either it just gives you a time out. only way to implement that function is to use a panic macro and cause an exception.
>>
>>109712341
:>don't let println! work
Goal achieved
>>
>>109712418
>loop { } doesn't work either it just gives you a time out
What?



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.