summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Martín Nieto <cmn@dwim.me>2014-07-08 09:56:16 +0200
committerCarlos Martín Nieto <cmn@dwim.me>2014-07-08 10:30:19 +0200
commit18eb6ec8233cb3cb607abdf289da6a57cc252bb2 (patch)
tree6613f8bd8a91ab5c8e09d8a2847625d3bb38fa74
parent9b87998c97fedcf0c22cef28bb0839ecd68c1efd (diff)
downloadlibgit2-18eb6ec8233cb3cb607abdf289da6a57cc252bb2.tar.gz
Documentation fixes
Fixup git_attr_value's comment to be recognised as documentation, and include the definitions needed for clang to parse reset.h such that it shows up in the documentation. This fixes #2430.
-rw-r--r--include/git2/attr.h29
-rw-r--r--include/git2/reset.h4
2 files changed, 20 insertions, 13 deletions
diff --git a/include/git2/attr.h b/include/git2/attr.h
index 3adbb2c24..0238f3dd7 100644
--- a/include/git2/attr.h
+++ b/include/git2/attr.h
@@ -76,25 +76,28 @@ GIT_BEGIN_DECL
*/
#define GIT_ATTR_HAS_VALUE(attr) (git_attr_value(attr) == GIT_ATTR_VALUE_T)
+/**
+ * Possible states for an attribute
+ */
typedef enum {
- GIT_ATTR_UNSPECIFIED_T = 0,
- GIT_ATTR_TRUE_T,
- GIT_ATTR_FALSE_T,
- GIT_ATTR_VALUE_T,
+ GIT_ATTR_UNSPECIFIED_T = 0, /**< The attribute has been left unspecified */
+ GIT_ATTR_TRUE_T, /**< The attribute has been set */
+ GIT_ATTR_FALSE_T, /**< The attribute has been unset */
+ GIT_ATTR_VALUE_T, /**< This attribute has a value */
} git_attr_t;
-/*
- * Return the value type for a given attribute.
+/**
+ * Return the value type for a given attribute.
*
- * This can be either `TRUE`, `FALSE`, `UNSPECIFIED` (if the attribute
- * was not set at all), or `VALUE`, if the attribute was set to
- * an actual string.
+ * This can be either `TRUE`, `FALSE`, `UNSPECIFIED` (if the attribute
+ * was not set at all), or `VALUE`, if the attribute was set to an
+ * actual string.
*
- * If the attribute has a `VALUE` string, it can be accessed normally
- * as a NULL-terminated C string.
+ * If the attribute has a `VALUE` string, it can be accessed normally
+ * as a NULL-terminated C string.
*
- * @param attr The attribute
- * @return the value type for the attribute
+ * @param attr The attribute
+ * @return the value type for the attribute
*/
GIT_EXTERN(git_attr_t) git_attr_value(const char *attr);
diff --git a/include/git2/reset.h b/include/git2/reset.h
index b8c580339..ea7217efe 100644
--- a/include/git2/reset.h
+++ b/include/git2/reset.h
@@ -7,6 +7,10 @@
#ifndef INCLUDE_git_reset_h__
#define INCLUDE_git_reset_h__
+#include "common.h"
+#include "types.h"
+#include "strarray.h"
+
/**
* @file git2/reset.h
* @brief Git reset management routines