Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Locked thread
hobbesmaster
Jan 28, 2008

yeah


i was just trying to get at "a thing that looks just like another thing, but is in fact nothing like that at all" is the root of every problem with c++

Adbot
ADBOT LOVES YOU

Progressive JPEG
Feb 19, 2003

I'd have figured it'd be "other language has thing, how do we shoehorn thing"

Bloody
Mar 3, 2013

i used play once. it was great, it pegged a server cpu at 100% under no load for several hours until the admin was like "uhhh???"

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder

Bloody posted:

i used play once. it was great, it pegged a server cpu at 100% under no load for several hours until the admin was like "uhhh???"

how else are you gonna fail fast? throw a few more cores on that puppy

hobbesmaster
Jan 28, 2008

Progressive JPEG posted:

I'd have figured it'd be "other language has thing, how do we shoehorn thing"

same idea really, those shoe horned things become abuse of notation at best in c++

HoboMan
Nov 4, 2010

Terrible Programmers: what font do you personally prefer to code in?

i hosed up my fonts by messing around and now i can't find one that don't suck

NihilCredo
Jun 6, 2011

iram omni possibili modo preme:
plus una illa te diffamabit, quam multæ virtutes commendabunt

HoboMan posted:

Terrible Programmers: what font do you personally prefer to code in?

i hosed up my fonts by messing around and now i can't find one that don't suck

https://github.com/nathco/Office-Code-Pro

HoboMan
Nov 4, 2010


that looks good, but what's up with that % sign?

Zaxxon
Feb 14, 2004

Wir Tanzen Mekanik

HoboMan posted:

Terrible Programmers: what font do you personally prefer to code in?

i hosed up my fonts by messing around and now i can't find one that don't suck

http://www.dafont.com/perfect-dos-vga-437.font

hobbesmaster
Jan 28, 2008

HoboMan posted:

that looks good, but what's up with that % sign?

based on the 5% in the preview window i'm assuming its an optimization for small font sizes?

fritz
Jul 26, 2003

hobbesmaster posted:

i hate the days after technical interviews where you second guess things you said like calling vector<bool> "a microcosm of everything wrong with c++"

c++ : "it seemed like a good idea at the time"

Sapozhnik
Jan 2, 2005

Nap Ghost
There are problems with Spring but everybody stampeding in the other direction and turning web applications into an amorphous unstructured soup with implicit behaviour all over the place is at least as bad.

There is more nuance to the problem of designing applications than "RIGID STRUCTURE GOOD" vs "RIGID STRUCTURE BAD".

For the record I wouldn't recommend using Spring for new projects.

jesus WEP
Oct 17, 2004


if youre building a webapp just ask What Would Shaggar Do and fire up visual studio

Plorkyeran
Mar 22, 2007

To Escape The Shackles Of The Old Forums, We Must Reject The Tribal Negativity He Endorsed

Progressive JPEG posted:

wait in what way? like how it's implemented as a bitmap underneath?

it's a type named vector<bool> that is not a vector of bools (or even a container at all according to the stl's definition), and the only reason it isn't just std::dynamic_bitset is because they wanted to show off how powerful template partial specialization was

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer
i use desdemona in a 17 point font

Soricidus
Oct 21, 2010
freedom-hating statist shill
the most appropriate font for your code is probably comic sans, op

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer
dont write code, you will only make bad things or make bad things worse

hobbesmaster
Jan 28, 2008

Plorkyeran posted:

it's a type named vector<bool> that is not a vector of bools (or even a container at all according to the stl's definition), and the only reason it isn't just std::dynamic_bitset is because they wanted to show off how powerful template partial specialization was

q: in c++11 can you use a range based for loop to modify a vector<bool> in place?
a: sure! its just:
code:
vector<bool> foo;
... //stuff with foo
for(auto &&x : foo){
    x = !x;  //or whatever other operation you want!
}
q: wait what what the gently caress is the type of x in that loop?
a: ¯\_(ツ)_/¯

HoboMan
Nov 4, 2010

welp, i crashed the test server and the sysadmin left already


... do-do i just go home?

JewKiller 3000
Nov 28, 2006

by Lowtax
spring is ok if you use spring boot and try not to think too hard about what all the magic annotations are doing

Sapozhnik
Jan 2, 2005

Nap Ghost
lol Java logging is such a fuckshow.

First there was Log4J
Then Sun added the very threadbare java.util.logging in Java 1.4
Then of course this is Java so we need a way to abstract between the two. Enter Commons Logging.
Then Java 1.5 came out with things like varargs, so the CL abstraction layer was replaced by the SLF4J abstraction layer
The abstraction layer needs at least one implementation, so enter Logback.

And that was the state of affairs for about 10-15 years. Oh and apparently JBoss and Jetty have their own internal metametaframeworks for switching among all this poo poo.

Now apparently Log4J is back in fashion? or at least they came out with a 2.0 version and its API is basically SLF4J except marginally better. Also there's a semi-decent systemd journal plugin for it.

Any sufficiently advanced Java is indistinguishable from parody.

LordSaturn
Aug 12, 2007

sadly unfunny

hobbesmaster posted:

q: in c++11 can you use a range based for loop to modify a vector<bool> in place?
a: sure! its just:
code:
vector<bool> foo;
... //stuff with foo
for(auto &&x : foo){
    x = !x;  //or whatever other operation you want!
}
q: wait what what the gently caress is the type of x in that loop?
a: ¯\_(ツ)_/¯

a special kind of gearbox for converting strong, narrow types into weak, wide ones

GameCube
Nov 21, 2006

hmm. cool. i'm getting java exceptions in my xamarin code when i run it on android. that's extremely cool

Sapozhnik
Jan 2, 2005

Nap Ghost

tef posted:

A DSL is what you have when code is written in one language and errors are reported in another

GameCube
Nov 21, 2006


poo poo

KidDynamite
Feb 11, 2005

GameCube posted:

hmm. cool. i'm getting java exceptions in my xamarin code when i run it on android. that's extremely cool

~native~

Bloody
Mar 3, 2013

consolas

Bloody
Mar 3, 2013

Plorkyeran posted:

it's a type named vector<bool> that is not a vector of bools (or even a container at all according to the stl's definition), and the only reason it isn't just std::dynamic_bitset is because they wanted to show off how powerful template partial specialization was


hobbesmaster posted:

q: in c++11 can you use a range based for loop to modify a vector<bool> in place?
a: sure! its just:
code:
vector<bool> foo;
... //stuff with foo
for(auto &&x : foo){
    x = !x;  //or whatever other operation you want!
}
q: wait what what the gently caress is the type of x in that loop?
a: ¯\_(ツ)_/¯

jesus christ what

c++ could have been good. it could've just been modernized c. but no. poo poo like this exists

Bloody
Mar 3, 2013

i think i have even less respect for people who choose to write c++ than people who choose to use plangs now that i think about it

hobbesmaster
Jan 28, 2008

don't use templates or its broken exception system and bam you have modern C

see: Qt

Sapozhnik
Jan 2, 2005

Nap Ghost
c++ is fundamentally busted for the reasons i outlined earlier. forcing you to use exceptions (constructors can only fail by throwing, without fallible constructors you lose basically c++ has to offer) in a language with no garbage collection sends you down into a particularly deep and dark circle of hell.

hobbesmaster
Jan 28, 2008

so if c++ is so broken what should i learn? c#? java?

HoboMan
Nov 4, 2010

yes

Condiv
May 7, 2008

Sorry to undo the effort of paying a domestic abuser $10 to own this poster, but I am going to lose my dang mind if I keep seeing multiple posters who appear to be Baloogan.

With love,
a mod


hobbesmaster posted:

so if c++ is so broken what should i learn? c#? java?

rust

Symbolic Butt
Mar 22, 2009

(_!_)
Buglord

Bloody posted:

i think i have even less respect for people who choose to write c++ than people who choose to use plangs now that i think about it

I chose both

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder

JawnV6
Jul 4, 2004

So hot ...
whats unmodern about C

Symbolic Butt
Mar 22, 2009

(_!_)
Buglord
dear terrible programmers thread, a lot of poo poo that I've been trying to do at work is actually... not going terribly wrong?

I think I may be getting better at coding and I can finally clear my conscience a bit for being a fraud

hobbesmaster
Jan 28, 2008


i would prefer to move to languages that more people use not less

Adbot
ADBOT LOVES YOU

comedyblissoption
Mar 15, 2006

  • Locked thread