Hi!

I added to my project in Visual Studio 2008 library to work with Neural Networks (FANN) http://www.geocities.com/freegoldbar/fann_cpp.zip.

When i try to compile, following error occurs:

c:\neu\neur\neur\src\include\fann_cpp.h(921) : error C2440: 'reinterpret_cast' : cannot convert from 'va_list' to 'const unsigned int *'
Conversion requires a constructor or user-defined-conversion operator, which can't be used by const_cast or reinterpret_cast
c:\neu\neur\neur\src\include\fann_cpp.h(971) : error C2440: 'reinterpret_cast' : cannot convert from 'va_list' to 'const unsigned int *'
Conversion requires a constructor or user-defined-conversion operator, which can't be used by const_cast or reinterpret_cast
c:\neu\neur\neur\src\include\fann_cpp.h(1018) : error C2440: 'reinterpret_cast' : cannot convert from 'va_list' to 'const unsigned int *'
Conversion requires a constructor or user-defined-conversion operator, which can't be used by const_cast or reinterpret_cast
c:\neu\neur\neur\src\include\fann_cpp.h(2484) : warning C4244: 'initializing' : conversion from 'float' to 'fann_type', possible loss of data
c:\neu\neur\neur\src\include\fann_cpp.h(3443) : error C3641: 'FANN::neural_net::internal_callback' : invalid calling convention '__stdcall ' for function compiled with /clr:pure or /clr:safe

its not possible to typecast a va_list object into an int* pointer. What you will have to do is create an int array, loop through the va_list and then pass the array to the function. google for va_list to get examples of looping through the list.

Thank you, i will try to do so.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.