Error running nvcc from command line: invalid redeclaration of type name "size_t"

I am trying to use managedCuda which should allow me to access kernels in .ptx files from C#. I would like to compile .cu files to .ptx, but even on the simplest example from the Cuda 5.0 Toolkit, I am getting an error.

I am using Windows 7 64-bit. I installed VS 2010 and then the Cuda 5.0 Toolkit. I added the location of cl.exe to the PATH. I ran vsvarsall.bat from the command line. Then I tried to compile one of the sample code files “nvcc vectorAddDrv.cu -ptx” and got the following errors:

d:program filesvsvcincludecodeanalysissourceannotations.h(29): error: invalid redeclaration of type name "size_t"
d:Program FilesVSVCINCLUDE

ew(51): error: first parameter of allocation must be of type “size_t”
d:Program FilesVSVCINCLUDE
ew(55): error: first parameter of allocation must be of type “size_t”
d:Program FilesVSVCINCLUDE
ew(67): error: first parameter of allocation must be of type “size_t”

d:program files
vidia gpu computing toolkitcudav5.0includecommon_functions.h(90):error: first parameter of allocation function must be of type “size_t”

(The forum software was treating single backslashes as escapes, so I doubled them.)

I get the same errors with other simple .cu files and without the -ptx option. Someone else seemed to have the same problem 2 months ago on StackOverflow with no answer. c++ - Problems when running nvcc from command line - Stack Overflow

Thanks in advance for any suggestions for how to get around this.