当前位置:网站首页>error: field ‘XXX’ declared as a function
error: field ‘XXX’ declared as a function
2022-07-24 09:45:00 【Jiang tengxia】
Problem description
Some time ago, I started a small project of smart home , Use it to practice your hands , I encountered this problem when compiling
Compiler error :

reason :
In structural elements A function pointer Wrong definition
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
#include <wiringSerial.h>
struct Command{
char cmdName[128];
char cmd[32];
int (*init)(); // It was dark purple before :int init();
int (*getCmd)(struct Command *voice); // It was dark purple before :int getCmd(struct Command *voice);
char log[1024];
int fd;
struct Command *next;
};
边栏推荐
- Compilation and linking of programs
- [assembly language practice] (II). Write a program to calculate the value of expression w=v- (x+y+z-51) (including code and process screenshots)
- Boundless dialogue | participate in the live broadcast on July 25 and win the prize
- Reading makes people improve my list
- What is the cloud native mid platform business architecture?
- The difference between classification and regression
- Es document CRUD
- Friends come to interview a unicorn company in Beijing at leisure. The interview question is priced at 25K
- Where is the bitbucket clone address
- [example] v-contextmenu right click menu component
猜你喜欢

MySQL query database capacity size

Es document CRUD

web安全入门-开源防火墙Pfsense安装配置

Recursion - if the function calls itself internally, then the function is a recursive function & the effect is the same as that of the loop & the push condition return should be added, otherwise stack

Do you really understand the concept of buffer? Take you to uncover the buffer zone~
![[assembly language practice] (II). Write a program to calculate the value of expression w=v- (x+y+z-51) (including code and process screenshots)](/img/0d/c8042ce5019d7dc5414dde5ebf1e8d.jpg)
[assembly language practice] (II). Write a program to calculate the value of expression w=v- (x+y+z-51) (including code and process screenshots)
![Cyclicbarrier and countdownlatch [concurrent programming]](/img/38/3305a0cdb6de40e1370cc93c8e5014.png)
Cyclicbarrier and countdownlatch [concurrent programming]
![CAS principle [concurrent programming]](/img/f0/77e7e1079f70198c601b0f1e25106e.png)
CAS principle [concurrent programming]

Foreign lead operation takes one month to collect money, and the sideline still needs it

Where is the bitbucket clone address
随机推荐
What happens from the input URL to the page load
[Luogu p5410] [template] extend KMP (Z function) (string)
Anti shake and throttling
[don't bother to strengthen learning] video notes (II) 1. What is Q-learning?
Dark king | analysis of zego low illumination image enhancement technology
CUDA day 2: GPU core and Sm core components [easy to understand]
Spark Learning: how to choose different association forms and mechanisms?
Huawei wireless device security policy configuration command
MySQL Basics (I) -- SQL Basics
CAS principle [concurrent programming]
Es search summary
web安全入门-开源防火墙Pfsense安装配置
The most complete solution for distributed transactions
缓冲区的概念真的理解么?带你揭开缓冲区的面纱~
MySQL基础篇(一)-- SQL基础
Do you really understand the concept of buffer? Take you to uncover the buffer zone~
Android Version Description security privacy 13
Onpropertychange property
Compilation and linking of programs
Color recognition of regions of interest in pictures and videos based on OpenCV