summaryrefslogtreecommitdiff
path: root/include/git2/attr.h
diff options
context:
space:
mode:
authorVicent Marti <tanoku@gmail.com>2012-07-15 14:11:58 +0200
committerVicent Marti <tanoku@gmail.com>2012-07-15 14:32:51 +0200
commit227f31311979a2fdb1ffc8dbcb4cf0737e7bc899 (patch)
tree7cd5a31b4a39d4b28b5ebd218ab07291463253c6 /include/git2/attr.h
parentd1af70b0509916abcb4724e0d8cdbee8ebf6bb2d (diff)
downloadlibgit2-227f31311979a2fdb1ffc8dbcb4cf0737e7bc899.tar.gz
attr: Rename the `git_attr__` exports
Pevents collisions with the original libgit, which also exports those exact symbols. Fixes #822
Diffstat (limited to 'include/git2/attr.h')
-rw-r--r--include/git2/attr.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/include/git2/attr.h b/include/git2/attr.h
index 8f5a1268d..fad7183da 100644
--- a/include/git2/attr.h
+++ b/include/git2/attr.h
@@ -30,7 +30,7 @@ GIT_BEGIN_DECL
* Then for file `xyz.c` looking up attribute "foo" gives a value for
* which `GIT_ATTR_TRUE(value)` is true.
*/
-#define GIT_ATTR_TRUE(attr) ((attr) == git_attr__true)
+#define GIT_ATTR_TRUE(attr) ((attr) == git_l_attr__true)
/**
* GIT_ATTR_FALSE checks if an attribute is set off. In core git
@@ -44,7 +44,7 @@ GIT_BEGIN_DECL
* Then for file `zyx.h` looking up attribute "foo" gives a value for
* which `GIT_ATTR_FALSE(value)` is true.
*/
-#define GIT_ATTR_FALSE(attr) ((attr) == git_attr__false)
+#define GIT_ATTR_FALSE(attr) ((attr) == git_l_attr__false)
/**
* GIT_ATTR_UNSPECIFIED checks if an attribute is unspecified. This
@@ -62,7 +62,7 @@ GIT_BEGIN_DECL
* file `onefile.rb` or looking up "bar" on any file will all give
* `GIT_ATTR_UNSPECIFIED(value)` of true.
*/
-#define GIT_ATTR_UNSPECIFIED(attr) (!(attr) || (attr) == git_attr__unset)
+#define GIT_ATTR_UNSPECIFIED(attr) (!(attr) || (attr) == git_l_attr__unset)
/**
* GIT_ATTR_HAS_VALUE checks if an attribute is set to a value (as
@@ -75,12 +75,12 @@ GIT_BEGIN_DECL
* string "lf" and `GIT_ATTR_SET_TO_VALUE(attr)` will return true.
*/
#define GIT_ATTR_HAS_VALUE(attr) \
- ((attr) && (attr) != git_attr__unset && \
- (attr) != git_attr__true && (attr) != git_attr__false)
+ ((attr) && (attr) != git_l_attr__unset && \
+ (attr) != git_l_attr__true && (attr) != git_attr__false)
-GIT_EXTERN(const char *) git_attr__true;
-GIT_EXTERN(const char *) git_attr__false;
-GIT_EXTERN(const char *) git_attr__unset;
+GIT_EXTERN(const char *) git_l_attr__true;
+GIT_EXTERN(const char *) git_l_attr__false;
+GIT_EXTERN(const char *) git_l_attr__unset;
/**
* Check attribute flags: Reading values from index and working directory.