函数声明而不是注释

Eps*_*tor 4 linux comments kernel

我注意到在Linux内核2.4文件sched.c中有一行说:

void scheduling_functions_start_here(void) { }
Run Code Online (Sandbox Code Playgroud)

还有一个说

void scheduling_functions_end_here(void) { }
Run Code Online (Sandbox Code Playgroud)

这种东西不应该写成评论吗?使用功能有什么好处?

Blo*_*ard 5

好吧,我刚刚做了一些谷歌搜索,现在可以稍微备份我的评论.查看process.c,第439行.

我没有太好地阅读C,但看起来它需要检查线程是否在调度函数中.