Page 1 of 1

what is true(23)

Posted: June 17th, 2017, 11:15 am
by best.ancloas
hey i am getting a bool output by a function i am calling, as a default true even when it does not satisfy the condition, and the output is in the form of true(23), or true(30)
the debugger is showing it in this form,
So can you tell me what does it mean and why i am getting this

Re: what is true(23)

Posted: June 17th, 2017, 4:01 pm
by chili
Bro, I have no idea what you mean. :D

Maybe post some code or a screenshot, we'll see what you got.

Re: what is true(23)

Posted: June 17th, 2017, 4:08 pm
by Zedtho
Your function is returning true(30) or true(23, while it only returns bools? Yes, just like Chili said, some code would be useful to figure this out. Is it an error message or actually what it is returning?

Re: what is true(23)

Posted: June 18th, 2017, 9:25 am
by albinopapa
My guess is he has some if statements returning true, and no return false after all the if statements. In other words, the function is returning and there is garbage being returned.

Re: what is true(23)

Posted: June 18th, 2017, 9:26 pm
by best.ancloas
Actually chili, since my code was having some troubles i just change all those parts which were having troubles,
but let me tell you this output true(23) was only shown by debugger in autos window.
thats why i just thought i should just post it in forum and ask you guys and this was showing it even when the condition should return it false, i thought may be it was returning some kind of garbage value,since i am a beginner I don't know clearly
by the way hi Chili and hi to all you guys i just joined the forum yesterday and this is really useful.

Re: what is true(23)

Posted: June 18th, 2017, 9:28 pm
by best.ancloas
i would definitely post the code from next time

Re: what is true(23)

Posted: June 19th, 2017, 12:52 am
by xu2201g
As a beginner it can be hard and confusing to make the first steps especially finding the right words to describe the issue for help - for me it was at least. So in case of doubt it wont do any harm to show the code you ve a problem with to find a solution.