Giter Club home page Giter Club logo

Comments (5)

daishengdong avatar daishengdong commented on August 16, 2024

这里因为前置声明的问题(tos_pend.h中使用到了k_task_t,但tos_task.h的包含在后面,所以在tos_pend.h中进行了前置声明),在有些其他编译器上也会报类型重定义的问题,但一般来说只是warning而不是error,你是否在gcc选项中开启了-Werror?

from tobudos.

ospanic avatar ospanic commented on August 16, 2024

我检查了下,确定没有-Werror参数,请问按照我的方式修改代码会有潜在问题吗?

from tobudos.

daishengdong avatar daishengdong commented on August 16, 2024

你的改法可以说的更具体一些么,你是在tos_pend.h里又定义了一遍k_task_st么

from tobudos.

daishengdong avatar daishengdong commented on August 16, 2024

比较好的改法是,在tos_task.h中,将

typedef struct k_task_st {
... ...
} k_task_t;

改为:
struct k_task_st {
... ...
};

后面我多验证一下把这个改法上库。

from tobudos.

daishengdong avatar daishengdong commented on August 16, 2024

上述改法已上库,可以拉取最新代码。

from tobudos.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.