Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Question
Monday, March 30, 2020 11:33 AM
I have made a program with C in Visual Studio which has been working fine. Lately, I have been doing some minor updates, and suddenly dozens of errors show up when compiling, but without showing any error in my own code. I have absolutely no idea why this happens and what to do about it, and therefore need some help. Here is the error messages:
1> Build started: Project: Raga_demo, Configuration: Debug Win32
1>Main.c
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vadefs.h(63,30): error C2054: expected '(' to follow 'testnummer'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vadefs.h(63,39): error C2085: 'uintptr_t': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vadefs.h(72,30): error C2085: 'va_list': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(61,56): warning C4081: expected ')'; found 'string'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(96,1): warning C4079: unexpected token 'string'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(96,1): warning C4081: expected 'newline'; found ')'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(197,36): error C2085: 'size_t': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(198,39): error C2085: 'ptrdiff_t': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(199,38): error C2085: 'intptr_t': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(209,30): error C2085: '__vcrt_bool': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(228,35): error C2085: 'wchar_t': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(338,46): error C2085: '__security_init_cookie': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(341,64): error C2146: syntax error: missing ')' before identifier '_StackCookie'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(341,64): error C2085: '__security_check_cookie': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(341,64): error C2146: syntax error: missing ',' before identifier '_StackCookie'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(341,76): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(342,67): error C2085: '__report_gsfailure': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(349,18): error C2085: 'uintptr_t': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(349,18): error C2146: syntax error: missing ',' before identifier '__security_cookie'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime.h(357,1): warning C4161: #pragma pack(pop...): more pops than pushes
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\excpt.h(15,56): warning C4081: expected ')'; found 'string'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\excpt.h(17,1): warning C4079: unexpected token 'string'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\excpt.h(17,1): warning C4081: expected 'newline'; found ')'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\excpt.h(28,24): error C2085: 'EXCEPTION_DISPOSITION': not in formal parameter list
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\excpt.h(38,5): error C2061: syntax error: identifier 'EXCEPTION_DISPOSITION'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\excpt.h(85,1): warning C4161: #pragma pack(pop...): more pops than pushes
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(270,28): error C2143: syntax error: missing ')' before 'const'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(270,28): error C2143: syntax error: missing '{' before 'const'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(270,34): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(275,9): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(283,24): error C2143: syntax error: missing ')' before 'const'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(283,24): error C2143: syntax error: missing '{' before 'const'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(284,24): error C2143: syntax error: missing ';' before 'const'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(287,35): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(562,20): error C2061: syntax error: identifier 'rsize_t'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\ucrt\corecrt.h(562,20): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(463,17): error C2061: syntax error: identifier 'WCHAR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(463,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(469,15): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(470,21): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(472,33): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(473,33): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(474,39): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(475,43): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(476,39): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(477,34): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(478,40): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(479,49): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(481,37): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(482,43): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(483,47): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(484,53): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(486,16): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(487,22): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(488,26): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(489,32): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(493,21): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(494,31): error C2143: syntax error: missing '{' before '*'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(560,15): error C2061: syntax error: identifier 'TCHAR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(560,15): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(560,20): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(561,15): error C2061: syntax error: identifier 'TBYTE'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(561,15): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(561,21): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(565,15): error C2061: syntax error: identifier 'LPTCH'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(565,15): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(565,20): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(566,16): error C2061: syntax error: identifier 'LPCTCH'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(566,16): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(566,22): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(567,16): error C2061: syntax error: identifier 'PTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(567,16): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(567,21): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(568,17): error C2061: syntax error: identifier 'PCTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(568,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(568,23): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(569,17): error C2061: syntax error: identifier 'PUTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(569,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(569,23): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(570,18): error C2061: syntax error: identifier 'PCUTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(570,18): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(570,25): error C2059: syntax error: ','
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(571,16): error C2061: syntax error: identifier 'LP'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(571,16): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(572,17): error C2061: syntax error: identifier 'PZZTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(572,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(573,18): error C2061: syntax error: identifier 'PCZZTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(573,18): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(574,18): error C2061: syntax error: identifier 'PUZZTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(574,18): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(575,19): error C2061: syntax error: identifier 'PCUZZTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(575,19): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(576,17): error C2061: syntax error: identifier 'PZPTSTR'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(576,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(577,16): error C2061: syntax error: identifier 'PNZTCH'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(577,16): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(578,17): error C2061: syntax error: identifier 'PCNZTCH'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(578,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(579,17): error C2061: syntax error: identifier 'PUNZTCH'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(579,17): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(580,18): error C2061: syntax error: identifier 'PCUNZTCH'
1>C:\Program Files (x86)\Windows Kits\10\Include\10.0.18362.0\um\winnt.h(580,18): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(25,49): error C2146: syntax error: missing ')' before identifier '_MaxCount'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(25,49): error C2081: 'size_t': name in formal parameter list illegal
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(25,49): error C2061: syntax error: identifier '_MaxCount'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(25,49): error C2059: syntax error: ';'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(26,5): error C2059: syntax error: ')'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(32,41): error C2146: syntax error: missing ')' before identifier '_Size'
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(32,41): error C2081: 'size_t': name in formal parameter list illegal
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.25.28610\include\vcruntime_string.h(32,41): fatal error C1003: error count exceeds 100; stopping compilation
1>Done building project "Raga_demo.vcxproj" -- FAILED.
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Thanks in advance.
Sincerely
All replies (8)
Monday, March 30, 2020 2:40 PM
Is testnummer a new element of your code?
Monday, March 30, 2020 6:12 PM
Yes. That's something I added recently, but still could compile my program without errors.
Tuesday, March 31, 2020 3:10 AM | 1 vote
Hi Gurunama,
Welcome to MSDN forum.
According to error message, they point to specific compile error, you may need to check your codes by following every error message. Focus on the minor updates you mentioned.
See compile errors from here: Compiler errors.
If possible, could you share us with your codes or reproduced sample(avoid private information) and upload it to OneDrive, then share link here. I will go to download and check it on my side.
Other suggestions for you to troubleshoot, if this issue is caused by VS IDE.
#1. Try to delete the hidden .vs folder > clean and rebuild your project.
#2. Try to repair Visual Studio from VS Installer > find VS > More > Repair.(this may take some time)
Hope this helps and any feedback will be expected.
Best Regards,
Tianyu
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
Tuesday, March 31, 2020 3:14 PM
Thank you for answering. I understand a little more now, but still don't find any solution.
I have done all your suggestions, including the repair installation, but it didn't change anything. I also went into the error list in the output window. The first line says error C2054, and then the following: "expected '(' to follow testnummer". However, I found this strange, as I have erased the variable "testnummer" and all references to it in the program. I also looked through all the array definitions to see if I had removed "=" from any of them. Based on the second line, error C2085, I also looked at all the occurences of ")" to see if I had erased a ";" after it. But found nothing. I have also specifically gone through those areas that I have edited lately.
I also recall that I very recently was asked to do an update of VS. But I am not sure if these problems started before or after the update.
Wednesday, April 1, 2020 1:48 AM
Hi Gurunama,
Thanks for your feedback.
I think this issue is strange, but as you know, the error messages point to specified error of codes, I’m afraid, this may be a little hard for us to check the issue without codes or samples.
But I could share you with some more suggestions which are helpful for you to troubleshoot from aspects of Visual Studio.
#1. Try to delete “ComponentModelCache” in every 16.0_XXXXX folder (Visual Studio cache) from C:\Users\username]\AppData\Local\Microsoft\VisualStudio\16.0_XXXXX
#2. Try to reset Visual Studio, by using this command line: “devenv /resetsettings” in “Developer Command Prompt for VS 2019” or going to Tools > Import and Export Settings > Reset all settings > Next > “No, just reset settings, overwriting my current settings” > Next > General > Finish.
#3. Try to disable or stop any third-party extensions temporarily from Extensions > Manage Extensions > Installed > Disable.
BTW, If this issue still persists, not sure if this is a potential issue, since you mentioned you have updated VS, I suggest you could report this issue directly to Visual Studio Product Team from Help > Send Feedback > Report a Problem.
Any feedback will be expected, and have a nice day.
Best Regards,
Tianyu
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
Wednesday, April 1, 2020 5:16 PM
Thanks again. I tried what you suggested, but it didn't help.
The problem with giving the code is that it is almost 5000 lines long, and that I might have done some minor editing at several places. But luckily I have an earlier version of my program that is still compiling and that I can build up again. I think I go by that for now. If the same issue should come up, I will come back to my question.
Sincerely
Thursday, April 2, 2020 12:50 AM
Hi Gurunama,
Thanks for your feedback.
Feel free to contact us, if you meet this same issue in the future again.
Have a nice day.
Sincerely,
Tianyu
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
Thursday, April 2, 2020 11:28 AM
Thank you the same.
Sincerely