|
flakeloaf posted:char *anArray = new char[100]; Nope, this is where you hosed up. &anArray is a pointer to a pointer to your 100 chars. That being said where did you get that other pointer, like from (&anArray)[1] or something? Also nice 32 bit dev machine for a clown to use at etc etc
|
![]() |
|
![]()
|
# ¿ Mar 21, 2023 01:11 |
|
MALE SHOEGAZE posted:JawnV6 (or anyone else): recommendations on where to get started learning assembly? it's about time. https://blogs.msdn.microsoft.com/oldnewthing/20040914-00/?p=37873
|
![]() |
|
Learn RISC v then Similar to MIPS except no delay slots or weird multiplication registers and in 2018 it is exactly ad relevant as MIPS ie not at all
|
![]() |
|
i mean there's something to be said for entire $1bn-$1tn market sectors not being intel's or qualcomm's bitch but we're at least a decade away from breaking those strangleholds it's cool in the meantime but yeah not very relevant beyond academic exercises.
|
![]() |
|
Luigi Thirty posted:I made a working button but idk why my app looks like windows 3.1 instead of windows 95 For Win95 style controls you have to pull in COMCTL32 (and you know, actually initialize it) (For WinXP and newer style controls you also have to have a WinSxS manifest resource that specifies version 6 of the common controls library, but you don't care about that on Win95 and SxS manifests didn't exist back then).
|
![]() |
|
I've recently had cause to poke around in the Windows Driver Framework it's.... surprisingly not-bad????
|
![]() |
|
a good article quote:What we need is a business rules engine quote:Initially there was hope that non-technical business users would be able to use the GUI to configure the application this is the programming equivalent of original sin
|
![]() |
|
cheque_some posted:What would you recommend for someone who is a self-taught terrible devopsing p-langing programmer but want to become a non-terrible programmer make a bunch of mistakes then think about and research ways to fix them. and do the actual fixing part as well ofc
|
![]() |
|
You must absolutely make your unit tests deterministic. So yeah hard code some plausible minimal test cases into your code. In situations where randomness is required your classes under test must take an RNG as a constructor param and you should supply an RNG that was initialized with a hard coded seed. Definitely have test cases for edge cases like new year. Seems like vat rates are a time series that requires a snapshot capability, so yeah build that whole time series service as a separate unit with its own separate unit tests. All else being equal you want your vat calculator (or anything else really) to have the data pushed to it instead of making it pull things. Vat exemption, well, no universal answer for that. Maybe you want your calculator to take a TaxRegime interface and have a method on that interface that takes the invoice date and whatever other properties the tax man cares about. Then have a PrivateCustomerTaxRegime and a VatExemptRegime where the latter returns a zero tax rate for everything and have an upper layer locate a suitable tax regime given a Customer object. Then test that upper layer separately. Sounds like you have an Invoice object with an effective date, a list of line items, and your tax calc function takes an Invoice and a TaxRegime. Elsewhere you have some other function that locates a TaxRegime given a Customer which you can test separately, and some other thing above all that to execute all the steps of the process. Or maybe that is a poo poo design idk. I don't know what the entire requirements doc looks like. So, push not pull where possible, think very hard about what your business logic should be a function of and cut the task into pieces accordingly, and let your testing plan inform your system design instead of the other way around.
|
![]() |
|
Well in that specific case it may be better to pass a Clock, but of course it depends on the exact task at hand
|
![]() |
|
There is no good way to use c++, only less bad ways
|
![]() |
|
Symbolic Butt posted:this is me reading this:
|
![]() |
|
yeah so just set up a regular postgres rds instance and be done with it bring lots of money
|
![]() |
|
ratbert90 posted:Modern C++ >= 14 is cool and good and makes C++ almost a higher level language. counterpoint: no
|
![]() |
|
ratbert90 posted:I like modern C++ and think it has it's place. this is like the "i listen to everything except rap and country" of programming opinions
|
![]() |
|
i got as far as emulating a mips cpu and a memory controller and sketched out some gpu register access dispatching for a psx-based arcade board before going "lol why the gently caress am i doing this i have a dozen other side projects withering atm" it did get a decent way through the boot ROM though, right up to the point where it would activate display scanout
|
![]() |
|
CRIP EATIN BREAD posted:this thread made me look into that emulator101.com page and now im designing UIs for a debugger in ANSI C. Why not implement a gdb remote debug interface
|
![]() |
|
![]()
|
![]() |
|
DONT THREAD ON ME posted:today i'm getting serious about c. gonna do the basic data structures and algos for however long that takes and then move on to c++. dont do c++ its super bad otoh c is fine for what it is
|
![]() |
|
there are places where you cannot avoid doing c++ (e.g. video games) because it is entrenched. there's nothing you can do in those circumstances but otherwise do not voluntarily use c++
|
![]() |
|
redleader posted:i'm extremely jealous of how motivated you are to do things
|
![]() |
|
god i really can't imagine actually voluntarily choosing to use c++ in 2018 when literally any other workable option is available
|
![]() |
|
Git's ui sucks but ugh yeah cmon people at least try Not gonna expect people to push immaculate rebaded change sets polished to a shine on the lathe of git interactive rebase but at least get the basic stuff right
|
![]() |
|
anybody remember transmeta their technology was pretty cool apart from the unfortunate aspect that it didn't actually do anything useful
|
![]() |
|
if there was a gamedev union and that union wasn't toothless then i'd totally work in game dev. the technical challenges seem very fun and interesting
|
![]() |
|
What is an ecs
|
![]() |
|
Com is surprisingly decent as long as you stay well away from com automation The registry stuff is a pain but that's about it
|
![]() |
|
I was writing perl way past its prime purely because I was annoyed at the lovely postgres driver situation in python that seemingly only got resolved fairly recently
|
![]() |
|
Still don't understand why people use vue instead of react Protip redux is poo poo but nobody is forcing you to use it, it's a totally independent thing
|
![]() |
|
Yarn add react-dom Then I guess press whatever button in vscode compiles your jsx typescript down to browser JavaScript Or if that's too much work let $ = React.createElement
|
![]() |
|
TheFluff posted:if you want a more expressive type system for your serialization format, just use protobufs. of course, it's not as portable, but that's the price you pay for complexity. in both xml and json you soon land in having to serialize almost everything as a string anyway. how aren't protobufs portable
|
![]() |
|
Kevin Mitnick P.E. posted:intellij generates all my compareTos, toStrings, and hashCodes maybe autovalue should do that for you instead
|
![]() |
|
why does postgres use neither mmap nor O_DIRECT in addition to having its own page cache
|
![]() |
|
orms are bad sprocs are worse bye
|
![]() |
|
It's OK to be whitespace? Yeah I got nothing
|
![]() |
|
Make a servlet filter that passes a subclass of httpservletrequestwrapper down the chain. Cache your request body there
|
![]() |
|
I'll just do a little bit of
|
![]() |
|
Luigi Thirty posted:terrible programmer status: risc-v business ![]()
|
![]() |
|
C++ has the worst goddamn standard library, hopefully we can at least agree on that Love to have a string type and text formatting routines that are completely and utterly worthless
|
![]() |
|
![]()
|
# ¿ Mar 21, 2023 01:11 |
|
People don't though, that's the problem Some are even perverted enough to use boost
|
![]() |