summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 64de356)
raw | patch | inline | side by side (parent: 64de356)
author | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Mon, 6 Jun 2005 17:12:31 +0000 (10:12 -0700) | ||
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Mon, 6 Jun 2005 17:12:31 +0000 (10:12 -0700) |
Only with gcc. It fixes some warnings for certain versions
of gcc, but not apparently all.
of gcc, but not apparently all.
cache.h | patch | blob | history |
index aa901d1f4669a6c615a70a924b119ded1fe7f464..95353a10a37d06bcc5d31f4d91cbb35f367b7c1a 100644 (file)
--- a/cache.h
+++ b/cache.h
#define DTYPE(de) DT_UNKNOWN
#endif
+#ifdef __GNUC__
+#define NORETURN __attribute__((__noreturn__))
+#else
+#define NORETURN
+#endif
+
/*
* Environment variables transition.
* We accept older names for now but warn.
extern char *sha1_to_hex(const unsigned char *sha1); /* static buffer result! */
/* General helper functions */
-extern void usage(const char *err);
-extern void die(const char *err, ...);
+extern void usage(const char *err) NORETURN;
+extern void die(const char *err, ...) NORETURN;
extern int error(const char *err, ...);
extern int base_name_compare(const char *name1, int len1, int mode1, const char *name2, int len2, int mode2);