Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
In time this becomes second nature, but Intellij IDEA will always highlight this for you. Good luck
-
@Djanjo using "==" to check equality between strings would be a bug, not a syntax error.
PS: you can use == in C#. Though it's better to use CompareTo with CultureInfo parameters to balance out possible cultural differences anyway. This applies to both C# and Java. -
Djanjo4497y@FunkDelegate
Like I said before..... A better IDE would explain you exactly what's wrong. Because == checks the references instead of the content. -
@Djanjo I don't know Java ide's that well. I've only used Netbeans a bit. So you mean your ide gives you a warning?
Related Rants
New to Java.
I was debugging for hours until I finally found the problem: "==" compares two strings' references, not their value.
I began to laugh tears!
Oh my fucking shit... I am a... damn it!
rant
java
freepascal doesn't hurt me that much