Microsoft
Software
Hardware
Network
Question : Incompatible types when assigning to type ‘fftw_complex’ from type ‘double *’
Hello,
I'm programming in C and am using the FFTW library, in which there is the data type fftw_complex defined as double[2]. Now consider two arrays of these:
fftw_complex a[10];
fftw_complex b[10];
if I do the following:
a[5] = b[5];
I get the error:
incompatible types when assigning to type ‘fftw_complex’ from type ‘double *’.
What's wrong with this? I realise I could just assign each of the two elements [0] and [1] but I would expect this to do the job...
I'm using Eclipse-CDT with gcc 4.4.3. Thanks!
Answer : Incompatible types when assigning to type ‘fftw_complex’ from type ‘double *’
typedef double fftw_complex[2];
a[5] is an array of two doubles, right.
The = operator does not apply to arrays.
Random Solutions
Include page headers when printing HTML pages with different headers on some of each page
How to block USB Disks using Windows 2008 R2 Domain Controller Group Policy
VMware Workstation 7.1 Won't Install
Lable (and other elements) not appearing in my code behind
How to notify the moderator of new posts?
net share system error 5 acces denied
Utilizing array gleamed from GetRows method in Access VBA
Virtual Disk 0 degraded Perc 5i integrated
How do I charge for a job?
Cisco 2950 Vlan for Voice