Silverfrost Forums

Welcome to our forums

Using C and C++ with FTN95

18 Dec 2014 2:51 #15222

I have a large body of code to produce printed output, and cannot get it to compile successfully. The issue appears to be with the 'bool' data type.

Is bool not allowed in SCC?

Also, function overloading does not appear to be possible.

Thanks, Bill

18 Dec 2014 6:15 #15226

Bill,

The SCC.hlp file ought to answer this, it's supposed to be accessible from PLATO or it is in the FTN95 install directory. HLP has not been the default helpfile format for a very long time, and Microsoft in its wisdom decided not to support it in Windows 7 (and presumably, later).

Worth keeping an old XP machine going!

Eddie

18 Dec 2014 7:48 #15227

The HELP file was not any help. I did find an option (by doing a CONFIG) that might have worked. I got past this error by defining a bool, and both true and false.

Now, can't get the C code to link with the FTN code. Much more obscure what the problem is there. If I include the C code for the interface routine in the FTN list of files, it gets linked in. But, if I create a library with this routine, there is a name difference that the linker is not picking up.

I posted a different forum post for this with some additional information.

I still like the product. But, if I can't get the 'C' code incorporated via a library call, ......

18 Dec 2014 9:10 #15230

Quoted from wahorger Is bool not allowed in SCC? Bill

Whether bool is a standard type or not depends on the version of the C standard in effect. The following code works with SCC.

#include <stdio.h>
#include <bool.h>
int main(){
int i=3,j=4;
bool x;
x=i > j;
printf('%s\\n',x ? 'TRUE' : 'FALSE');
}

Eddie, you need not resurrect XP just to use WinHelp; see http://www.microsoft.com/en-us/download/details.aspx?id=91

18 Dec 2014 9:13 #15231

Thanks for the bool.h tip.

Bill

18 Dec 2014 10:02 #15232

I need XP to run my slide scanner: in Windows 7 its drivers conflict with my NAS!

Eddie

Please login to reply.