【问题标题】:Doxygen not including C bit-field documentationDoxygen 不包括 C 位域文档
【发布时间】:2013-07-12 16:44:31
【问题描述】:

我在 C 程序中创建了几个伪寄存器结构,并使用结构和联合来实现字段并将所有寄存器收集在一起。

每个成员、字段等都有记录 cmets,但生成的文档没有显示位字段的文档...我该如何解决这个问题,以便他们的文档包含在输出中?

我的实现示例(未显示的是 bitNName cmets):

/** This shows in documentation. */
union REG1 {
    int all;            /**< This shows in documentation. */
    struct REG1BITS {
        int bit1Name:1; /**< This is not in documentation. */
        int bit2Name:1; /**< This is not in documentation. */
    } bit;              /**< This shows in documentation. */
};

/** This shows in documentation. */
union REG3 {
    int all;            /**< This shows in documentation. */
    struct REG3BITS {
        int bit1Name:1; /**< This is not in documentation. */
        int bit2Name:1; /**< This is not in documentation. */
    } bit;              /**< This shows in documentation. */
};

/** This shows in documentation. */
extern struct ALLREGS {
    union REG1 reg1Name; /**< This shows in documentation. */
    union REG1 reg2Name; /**< This shows in documentation. */
    union REG3 reg3Namd; /**< This shows in documentation. */
} CollectedRegs;

更新:只是想这可能是因为包含结构的位字段都被命名为位 - 这是 doxygen 的冲突吗?

【问题讨论】:

  • Doxygen 支持位域。使用 doxygen 1.8.4 版,我没有看到您的示例(和默认配置文件)存在问题。您使用的是哪个版本的 doxygen?
  • @doxygen 啊,我在 1.8.3.1,我想我需要更新一下。
  • @doxygen 这实际上没有任何区别。 ALL_REGS 和 REGn 记录在数据结构和位下,并且都记录为联合引用页面上的数据字段(尽管不在数据字段页面上),但根本没有记录 bitnName 字段...

标签: c doxygen bit-fields


【解决方案1】:

这个问题在更新的 doxygen 版本中得到了解决:)

【讨论】:

    猜你喜欢
    • 2015-07-06
    • 2012-05-01
    • 2011-03-27
    • 2015-01-14
    • 1970-01-01
    • 1970-01-01
    • 2021-02-04
    • 2011-02-25
    相关资源
    最近更新 更多