Closed sbOogway closed 1 year ago
Looks like some real swag for sure. However it's not good to put all utilities in a single file. Maybe split it into
lib/log.hpp
(with a namespace calledlog
->log::error
) andlib/time.hpp
(without a namespace)
@Zedritsch thank u for the feedback bro, appreciate it
I assume everyone knows about stdio.h
and printf
and stuff, why is nobody using it? Is there something wrong with it? Genuinely trying to learn here lol
@RedstoneWizard08 what u mean bruv?
I assume everyone knows about
stdio.h
andprintf
and stuff, why is nobody using it? Is there something wrong with it? Genuinely trying to learn here lol
@RedstoneWizard08 stdio.h
is a part of the C
standard library. Developers often prefer C++
equivalents (like iostream
) as they are often more memory save and/or more compatible with other parts of the C++
standard library. Also, although C++
is a superset of C
, there are a few cases in which C
code does not compile in C++
as it would with a C compiler. So it's a good practice to deal with these languages separatly.
Okay, that makes a lot of sense. I keep thinking of it like a JS/TS sort of relationship, where technically JS can be TS code, but TS is better. I guess C and C++ are a lot more different than I thought. This is why I like Rust lol. Only one way to do things normally. (Pretends str
and String
don't both exist.)
@orosmatthew bro take a look and do something
Thanks for your enthusiasm for the project, but as of now I will not be accepting major pull requests to better keep in sync with the videos and things change quite drastically between videos. I will leave this open if I decide to change my mind in the future.
Okay, that makes a lot of sense. I keep thinking of it like a JS/TS sort of relationship, where technically JS can be TS code, but TS is better. I guess C and C++ are a lot more different than I thought. This is why I like Rust lol. Only one way to do things normally. (Pretends
str
andString
don't both exist.)
I know it's been a few days, but I found a ressource that shows a really good example of the difference between C
and C++
:
https://youtu.be/c-NyXKbqmQc?t=52
swagging 4evah. need to delete some includes