call to buffer has incorrect number of arguments

If you have a simple question and just want an answer.
Post Reply
osch
Member
Posts: 12
Joined: Sun Sep 03, 2017 10:12 pm

call to buffer has incorrect number of arguments

Post by osch »

Hello! I started getting this error when i build my project and i cannot figure out why. Does anyone know where im supposed to look in my code for this? I cant figure out what i did. The project has multiple modules and files and i suspect one of the modules is broken, but i cannot figure out which one.

xmake CONFIG=Default all
Checking build modules
Propagating analysis
....../main.xc: warning: call to buffer has incorrect number of arguments
xmake[1]: *** [.build/pca.xml] Error 255
xmake: *** [analyze] Error 2


Gothmag
XCore Addict
Posts: 129
Joined: Wed May 11, 2016 3:50 pm

Post by Gothmag »

I'd start in main.xc and go from there. Any headers directly included there as well.
osch
Member
Posts: 12
Joined: Sun Sep 03, 2017 10:12 pm

Post by osch »

Okay so i figured out what caused this issue and im hoping this might help others in the future. I had copied a function from a post on this forum which name was buffer:

void buffer(server interface var_shared_if i_shared[2]){

This caused this compiler error and made xpca.exe stopped working. I have changed the name of the function and it works just fine now.
robertxmos
XCore Addict
Posts: 169
Joined: Fri Oct 23, 2015 10:23 am

Post by robertxmos »

It sounds like the dependencies and their timestamps got out of sync.
One of the files had changed, but the artifacts were not being rebuilt.
The easiest (but annoying) fix for this is to run 'xmake clean' to remove all artifacts, followed by 'xmake all'.
Post Reply