1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-24 11:31:31 +00:00

Merge pull request #1809 from cc65/revert-1805-something_to_pull

Revert "rename '_poserror' to '__poserror'"
This commit is contained in:
Bob Andrews 2022-07-24 18:22:37 +02:00 committed by GitHub
commit 073443d865
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 24 additions and 24 deletions

View File

@ -627,7 +627,7 @@ communication, see also <tt>testcode/lib/ser-test.c</tt>.
<sect1><tt/stdio.h/<label id="stdio.h"><p> <sect1><tt/stdio.h/<label id="stdio.h"><p>
<itemize> <itemize>
<item><ref id="__poserror" name="__poserror"> <item><ref id="_poserror" name="_poserror">
<item><ref id="clearerr" name="clearerr"> <item><ref id="clearerr" name="clearerr">
<!-- <item><ref id="fclose" name="fclose"> --> <!-- <item><ref id="fclose" name="fclose"> -->
<!-- <item><ref id="fdopen" name="fdopen"> --> <!-- <item><ref id="fdopen" name="fdopen"> -->
@ -1058,14 +1058,14 @@ It returns 1 if it does.
</descrip> </descrip>
</quote> </quote>
<sect1>__poserror<label id="__poserror"><p> <sect1>_poserror<label id="_poserror"><p>
<quote> <quote>
<descrip> <descrip>
<tag/Function/Print an error message for the error in <tt/_oserror/. <tag/Function/Print an error message for the error in <tt/_oserror/.
<tag/Header/<tt/<ref id="stdio.h" name="stdio.h">/ <tag/Header/<tt/<ref id="stdio.h" name="stdio.h">/
<tag/Declaration/<tt/void __fastcall__ __poserror (const char* msg);/ <tag/Declaration/<tt/void __fastcall__ _poserror (const char* msg);/
<tag/Description/<tt/__poserror/ prints an error message to <tt/stderr/. If <tag/Description/<tt/_poserror/ prints an error message to <tt/stderr/. If
<tt/msg/ is not <tt/NULL/ and not an empty string, it is printed followed by <tt/msg/ is not <tt/NULL/ and not an empty string, it is printed followed by
a colon and a blank. Then the error message for the current contents of a colon and a blank. Then the error message for the current contents of
<tt/_oserror/ are printed followed by a newline. The message output is the <tt/_oserror/ are printed followed by a newline. The message output is the
@ -5856,7 +5856,7 @@ be used in presence of a prototype.
</itemize> </itemize>
<tag/Availability/ISO 9899 <tag/Availability/ISO 9899
<tag/See also/ <tag/See also/
<ref id="__poserror" name="__poserror">, <ref id="_poserror" name="_poserror">,
<ref id="strerror" name="strerror"> <ref id="strerror" name="strerror">
<tag/Example/None. <tag/Example/None.
</descrip> </descrip>

View File

@ -147,7 +147,7 @@ int __fastcall__ vfscanf (FILE* f, const char* format, __va_list ap);
FILE* __fastcall__ fdopen (int fd, const char* mode); /* Unix */ FILE* __fastcall__ fdopen (int fd, const char* mode); /* Unix */
int __fastcall__ fileno (FILE* f); /* Unix */ int __fastcall__ fileno (FILE* f); /* Unix */
#endif #endif
void __fastcall__ __poserror (const char* msg); /* cc65 */ void __fastcall__ _poserror (const char* msg); /* cc65 */
/* Masking macros for some functions */ /* Masking macros for some functions */
#define getc(f) fgetc (f) /* ANSI */ #define getc(f) fgetc (f) /* ANSI */

View File

@ -1,6 +1,6 @@
/*****************************************************************************/ /*****************************************************************************/
/* */ /* */
/* __poserror.c */ /* _poserror.c */
/* */ /* */
/* Output a system dependent error code */ /* Output a system dependent error code */
/* */ /* */
@ -39,7 +39,7 @@
void __fastcall__ __poserror (const char* msg) void __fastcall__ _poserror (const char* msg)
{ {
/* Fetch the message that corresponds to _oserror */ /* Fetch the message that corresponds to _oserror */
const char* errormsg = _stroserror (_oserror); const char* errormsg = _stroserror (_oserror);

View File

@ -1,5 +1,5 @@
/* /*
** __poserror.c ** _poserror.c
** **
** Maciej 'YTM/Elysium' Witkowiak, 25.04.2003 ** Maciej 'YTM/Elysium' Witkowiak, 25.04.2003
*/ */
@ -9,7 +9,7 @@
#include <errno.h> #include <errno.h>
#include <geos.h> #include <geos.h>
void __fastcall__ __poserror (const char* msg) void __fastcall__ _poserror (const char* msg)
{ {
const char *errmsg = _stroserror(_oserror); const char *errmsg = _stroserror(_oserror);

View File

@ -65,7 +65,7 @@ void foobar (void)
void main(int /*argc*/, char *argv[]) void main(int /*argc*/, char *argv[])
{ {
if (OpenRecordFile(argv[0])) { if (OpenRecordFile(argv[0])) {
__poserror("OpenRecordFile"); _poserror("OpenRecordFile");
return; return;
} }
@ -73,7 +73,7 @@ void main(int /*argc*/, char *argv[])
"Click OK to call Overlay One."); "Click OK to call Overlay One.");
if (PointRecord(1)) { if (PointRecord(1)) {
__poserror("PointRecord.1"); _poserror("PointRecord.1");
return; return;
} }
@ -82,7 +82,7 @@ void main(int /*argc*/, char *argv[])
** size specific to a certain program. ** size specific to a certain program.
*/ */
if (ReadRecord(OVERLAY_ADDR, OVERLAY_SIZE)) { if (ReadRecord(OVERLAY_ADDR, OVERLAY_SIZE)) {
__poserror("ReadRecord.1"); _poserror("ReadRecord.1");
return; return;
} }
@ -96,7 +96,7 @@ void main(int /*argc*/, char *argv[])
"Click OK to call Overlay Two."); "Click OK to call Overlay Two.");
if (PointRecord(2)) { if (PointRecord(2)) {
__poserror("PointRecord.2"); _poserror("PointRecord.2");
return; return;
} }
@ -104,7 +104,7 @@ void main(int /*argc*/, char *argv[])
** program. This implies that an overlay can never load another overlay. ** program. This implies that an overlay can never load another overlay.
*/ */
if (ReadRecord(OVERLAY_ADDR, OVERLAY_SIZE)) { if (ReadRecord(OVERLAY_ADDR, OVERLAY_SIZE)) {
__poserror("ReadRecord.2"); _poserror("ReadRecord.2");
return; return;
} }
@ -114,19 +114,19 @@ void main(int /*argc*/, char *argv[])
"Click OK to call Overlay Three."); "Click OK to call Overlay Three.");
if (PointRecord(3)) { if (PointRecord(3)) {
__poserror("PointRecord.3"); _poserror("PointRecord.3");
return; return;
} }
if (ReadRecord(OVERLAY_ADDR, OVERLAY_SIZE)) { if (ReadRecord(OVERLAY_ADDR, OVERLAY_SIZE)) {
__poserror("ReadRecord.3"); _poserror("ReadRecord.3");
return; return;
} }
foobar(); foobar();
if (CloseRecordFile()) { if (CloseRecordFile()) {
__poserror("CloseRecordFile"); _poserror("CloseRecordFile");
return; return;
} }
} }

View File

@ -58,7 +58,7 @@ int main(void)
printf("Creating file: %s\n", name1); printf("Creating file: %s\n", name1);
file = fopen(name1, "w"); file = fopen(name1, "w");
if (file == NULL) { if (file == NULL) {
__poserror("Disk error making first file"); _poserror("Disk error making first file");
return EXIT_FAILURE; return EXIT_FAILURE;
} }
fclose(file); fclose(file);
@ -66,7 +66,7 @@ int main(void)
/* Verify that the file-name exists now. */ /* Verify that the file-name exists now. */
file = fopen(name1, "r"); file = fopen(name1, "r");
if (file == NULL) { if (file == NULL) {
__poserror("Cannot find first name"); _poserror("Cannot find first name");
return EXIT_FAILURE; return EXIT_FAILURE;
} }
fclose(file); fclose(file);
@ -78,7 +78,7 @@ int main(void)
printf("Renaming %s to %s\n", name1, name2); printf("Renaming %s to %s\n", name1, name2);
r = rename(name1, name2); r = rename(name1, name2);
if (r < 0) { if (r < 0) {
__poserror("rename() failed"); _poserror("rename() failed");
return EXIT_FAILURE; return EXIT_FAILURE;
} }
@ -86,14 +86,14 @@ int main(void)
file = fopen(name1, "r"); file = fopen(name1, "r");
if (file != NULL) { if (file != NULL) {
fclose(file); fclose(file);
__poserror("First name still exists"); _poserror("First name still exists");
return EXIT_FAILURE; return EXIT_FAILURE;
} }
/* Verify that the second file-name exists now. */ /* Verify that the second file-name exists now. */
file = fopen(name2, "r"); file = fopen(name2, "r");
if (file == NULL) { if (file == NULL) {
__poserror("Cannot find second name"); _poserror("Cannot find second name");
return EXIT_FAILURE; return EXIT_FAILURE;
} }
fclose(file); fclose(file);
@ -104,7 +104,7 @@ int main(void)
printf("Removing %s\n", name2); printf("Removing %s\n", name2);
r = remove(name2); r = remove(name2);
if (r < 0) { if (r < 0) {
__poserror("remove() failed"); _poserror("remove() failed");
return EXIT_FAILURE; return EXIT_FAILURE;
} }