consistent ATTRNORETURN prefix and NORETURN suffix

This commit is contained in:
nhmall
2025-05-30 22:01:20 -04:00
parent 50e5715ca5
commit 9ef5e886ee
10 changed files with 13 additions and 13 deletions

View File

@@ -319,7 +319,7 @@ hacklib.olb: $(HACKLIBOBJLIST)
$(INCL)nhlua.h:
echo "/* nhlua.h - generated by Makefile.vms */" > $@
@echo \#"include ""$(LUASRCINCDIR)lua.h""" >> $@
@echo "LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
@echo "ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
@echo \#"include ""$(LUASRCINCDIR)lualib.h""" >> $@
@echo \#"include ""$(LUASRCINCDIR)lauxlib.h""" >> $@
@echo "/*nhlua.h*/" >> $@
@@ -327,7 +327,7 @@ $(INCL)nhlua.h:
#$(INCL)nhlua.h:
# echo "/* nhlua.h - generated by -vms9 */" > $@
# @echo \#"include ""sys$$common:[lua.include]lua.h""" >> $@
# @echo "LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
# @echo "ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
# @echo \#"include ""sys$$common:[lua.include]lualib.h""" >> $@
# @echo \#"include ""sys$$common:[lua.include]lauxlib.h""" >> $@
# @echo "/*nhlua.h*/" >> $@

View File

@@ -314,7 +314,7 @@ dofiles-nodlb:
$(INCL)nhlua.h:
echo "/* nhlua.h - generated by top-level Makefile.vms */" > $@
@echo \#"include ""lua.h""" >> $@
@echo "LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
@echo "ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
@echo \#"include ""lualib.h""" >> $@
@echo \#"include ""lauxlib.h""" >> $@
@echo "/*nhlua.h*/" >> $@

View File

@@ -377,7 +377,7 @@ $ set file/att=(RFM:STM) [-.include]nhlua.h
$ open/Append f [-.include]nhlua.h
$ write f "/* nhlua.h - generated by vmsbuild.com */"
$ write f "#include ""[-.lib.lua''luaver'.src]lua.h"""
$ write f "LUA_API int (lua_error) (lua_State *L) NORETURN;"
$ write f "ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN;"
$ write f "#include ""[-.lib.lua''luaver'.src]lualib.h"""
$ write f "#include ""[-.lib.lua''luaver'.src]lauxlib.h"""
$ write f "/*nhlua.h*/"

View File

@@ -16,8 +16,8 @@
int debuggable = 0; /* 1 if we can debug or show a call trace */
ATTRNORETURN void vms_exit(int);
ATTRNORETURN void vms_abort(void);
ATTRNORETURN void vms_exit(int) NORETURN;
ATTRNORETURN void vms_abort(void) NORETURN;
/* first arg should be unsigned long but <lib$routines.h> has unsigned int */

View File

@@ -435,7 +435,7 @@ NHLUAH = $(INCL)/nhlua.h
$(NHLUAH):
echo "/* nhlua.h - generated by GNUmakefile */" > $@
@echo "#include \"$(LUASRC)/lua.h\"" >> $@
@echo "LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
@echo "ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN;" >>$@
@echo "#include \"$(LUASRC)/lualib.h\"" >> $@
@echo "#include \"$(LUASRC)/lauxlib.h\"" >> $@
@echo "/*nhlua.h*/" >> $@

View File

@@ -1769,7 +1769,7 @@ $(OUTL)utility.tag: $(INCL)nhlua.h outldir$(TARGET_CPU).tag $(OUTLHACKLIB) $(U)t
$(INCL)nhlua.h:
@echo /* nhlua.h - generated by Makefile from Makefile.nmake */ > $@
@echo #include "lua.h" >> $@
@echo LUA_API int (lua_error) (lua_State *L) NORETURN; >> $@
@echo ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN; >> $@
@echo #include "lualib.h" >> $@
@echo #include "lauxlib.h" >> $@
@echo /*nhlua.h*/ >> $@

View File

@@ -59,7 +59,7 @@ fetch-pdcurses:
..\..\..\..\include\nhlua.h:
@echo /* nhlua.h - generated by Makefile from fetchprereq.nmake */ > $@
@echo #include "lua.h" >> $@
@echo LUA_API int (lua_error) (lua_State *L) NORETURN; >> $@
@echo ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN; >> $@
@echo #include "lualib.h" >> $@
@echo #include "lauxlib.h" >> $@
@echo /*nhlua.h*/ >> $@

View File

@@ -172,7 +172,7 @@
<Message Text="Generating $(IncDir)nhlua.h" />
<Exec Command="echo /* nhlua.h - generated by hacklib.vcxproj ClCompile */ &gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo #include %22lua.h%22 &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo LUA_API int (lua_error) (lua_State *L) NORETURN; &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN; &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo #include %22lualib.h%22 &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo #include %22lauxlib.h%22 &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo /*nhlua.h*/ &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />

View File

@@ -471,7 +471,7 @@
<Message Text="Generating $(IncDir)nhlua.h" />
<Exec Command="echo /* nhlua.h - generated by lualib.vcxproj ClCompile */ &gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo #include %22lua.h%22 &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo LUA_API int (lua_error) (lua_State *L) NORETURN; &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo ATTRNORETURN LUA_API int (lua_error) (lua_State *L) NORETURN; &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo #include %22lualib.h%22 &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo #include %22lauxlib.h%22 &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />
<Exec Command="echo /*nhlua.h*/ &gt;&gt; nhlua.h" WorkingDirectory="$(IncDir)" />

View File

@@ -90,10 +90,10 @@ int util_strncmpi(const char *s1, const char *s2, size_t sz);
#ifdef UNIX
#define nethack_exit exit
void nh_terminate(int) NORETURN; /* bwrite() calls this */
ATTRNORETURN void nh_terminate(int) NORETURN; /* bwrite() calls this */
static void chdirx(const char *);
#else
extern void nethack_exit(int) NORETURN;
ATTRNORETURN extern void nethack_exit(int) NORETURN;
#ifdef WIN32
boolean get_user_home_folder(char *homebuf, size_t sz);
int GUILaunched;