Strange compiler report on Flowcode 6.1.0.0

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 6.

Moderator: Benj

Mathy
Posts: 333
Joined: Mon Oct 05, 2009 2:39 pm
Has thanked: 30 times
Been thanked: 33 times
Contact:

Strange compiler report on Flowcode 6.1.0.0

Postby Mathy » Fri Jan 09, 2015 3:14 pm

Hello,

I have a strange compiler report when compiling with this kind of calculation :

ASCII = "1000"


ASCII is declared as a String
The compiler report me this :

Flowcode1.c:90: warning: pointer targets in passing argument 1 of 'FCI_SCOPY' differ in signedness
Flowcode1.c:90: warning: passing argument 3 of 'FCI_SCOPY' discards qualifiers from pointer target type

In the real life, my code is working but as I have lots of calculation icon like this one, compilation take long time because of all those report.

It is something I'm doing wrong ?

Thank you for your help :)

kersing
Valued Contributor
Valued Contributor
Posts: 1873
Joined: Wed Aug 27, 2008 10:31 pm
Location: Netherlands
Has thanked: 530 times
Been thanked: 1040 times
Contact:

Re: Strange compiler report on Flowcode 6.1.0.0

Postby kersing » Fri Jan 09, 2015 3:34 pm

You are not doing something wrong. Strictly speaking Flowcode is doing something wrong, the C code generated is not standards compliant as noted by the compiler. I would recommend to check the warnings (tedious as it might be) as these warnings may obscure warnings you need to take into account because of errors in your code.

Hopefully this will be solved in a future release.
These users thanked the author kersing for the post:
LeighM (Fri Jan 09, 2015 3:56 pm)
Rating: 5.26%
 
“Integrity is doing the right thing, even when no one is watching.”

― C.S. Lewis

User avatar
LeighM
Matrix Staff
Posts: 1911
Joined: Tue Jan 17, 2012 10:07 am
Has thanked: 460 times
Been thanked: 646 times
Contact:

Re: Strange compiler report on Flowcode 6.1.0.0

Postby LeighM » Fri Jan 09, 2015 3:55 pm

No, it’s nothing you are doing wrong.
For historic reasons, Flowcode has ended up with a mix of signed and unsigned char definitions where strings are used. I think it’s in the plan to clean this all up at some point.
As you have found, you can ignore the warnings.

edit: As kersing makes a good point, to ensure these warnings are not hiding something that might need attention.
Especially as string concatenation (particularly when converting numbers) can give unexpected results.