ObjFW  History of src/exceptions/OFException.m of f2a8bdf254c3b166

History of the file that is called src/exceptions/OFException.m at check-in f2a8bdf254c3b166

2024-01-02
17:17
Update copyright file: [aa2fc710c4] check-in: [26ddd2e4e4] user: js, branch: trunk, size: 8201 [annotate] [blame] [check-ins using] [diff]
2023-01-06
09:04
Update copyright file: [d70693599a] check-in: [8939cbdb52] user: js, branch: trunk, size: 8201 [annotate] [blame] [check-ins using] [diff]
2022-09-29
21:26
OFException: Provide stack trace addresses file: [700714ee53] check-in: [f93fae010f] user: js, branch: trunk, size: 8201 [annotate] [blame] [check-ins using] [diff]
2022-02-12
07:46
Update copyright file: [21f1fa3002] check-in: [1a86b8175b] user: js, branch: trunk, size: 7468 [annotate] [blame] [check-ins using] [diff]
2021-04-29
23:24
Clean up struct and enum typedefs

With TYPEDEF_HIDES_STRUCT set, Doxygen properly handles anonymous
structs and enums that are typedef'd. file: [5ced4219b2] check-in: [2fcf5a3052] user: js, branch: trunk, size: 7468 [annotate] [blame] [check-ins using] [diff]

2021-04-25
11:05
A few last renames file: [d414760729] check-in: [27103855c2] user: js, branch: new-naming-convention, size: 7467 [annotate] [blame] [check-ins using] [diff]
2021-04-18
22:56
Rename all symbols marked extern file: [133314f808] check-in: [e73c65a849] user: js, branch: new-naming-convention, size: 7481 [annotate] [blame] [check-ins using] [diff]
20:51
Rename everything in several smaller files file: [a20480ca4a] check-in: [35de667566] user: js, branch: new-naming-convention, size: 7486 [annotate] [blame] [check-ins using] [diff]
15:55
Rename all functions in macros.h file: [f25e1cbb70] check-in: [7392685ffc] user: js, branch: new-naming-convention, size: 7480 [annotate] [blame] [check-ins using] [diff]
2021-04-17
16:24
of_mutex_t -> OFPlainMutex

Also rename of_rmutex_t -> OFPlainRecursiveMutex. file: [7a4b36018b] check-in: [dfd52d5220] user: js, branch: new-naming-convention, size: 7481 [annotate] [blame] [check-ins using] [diff]

2021-01-02
22:04
Update copyright file: [c381d0d5f6] check-in: [374e1a1bfa] user: js, branch: trunk, size: 7467 [annotate] [blame] [check-ins using] [diff]
2020-12-21
02:34
Don't use OFMutex in constructors

It's possible OFMutex is not loaded yet. file: [9ab19e4a0d] check-in: [f02b51feba] user: js, branch: trunk, size: 7556 [annotate] [blame] [check-ins using] [diff]

00:36
Add destructors for global mutexes file: [c2351f2243] check-in: [68214158ee] user: js, branch: trunk, size: 7415 [annotate] [blame] [check-ins using] [diff]
2020-12-20
21:26
Return error instead of using errno for threading

errno is problematic for Amiga libraries and is also not thread-safe on
some systems, even though it should. file: [aa89efc62e] check-in: [5b37fbeb82] user: js, branch: trunk, size: 7593 [annotate] [blame] [check-ins using] [diff]

2020-05-17
14:08
Add support for non-Unicode Windows in all classes file: [bf7ff24437] check-in: [494acfb3e0] user: js, branch: trunk, size: 7581 [annotate] [blame] [check-ins using] [diff]
2020-05-10
15:33
Fix building with --disable-sockets on Windows file: [91a0048000] check-in: [efbb4a8eb4] user: js, branch: trunk, size: 7085 [annotate] [blame] [check-ins using] [diff]
2020-04-05
13:23
configure: Check return type of strerror_r

Just checking for _GNU_SOURCE is not enough, because musl still returns
int even with _GNU_SOURCE, despite the musl header explicitly checking
for _GNU_SOURCE. file: [3cf46d2139] check-in: [af603291de] user: js, branch: trunk, size: 7051 [annotate] [blame] [check-ins using] [diff]

2020-01-02
01:51
Update copyright file: [0f0c49d47c] check-in: [c7f0229795] user: js, branch: trunk, size: 7066 [annotate] [blame] [check-ins using] [diff]
2019-08-01
20:14
Split threading.[hm] into multiple files

This allows the runtime to only link against the parts it needs, without
pulling in unnecessary parts like thread spawning, TLS and conditions. file: [6ae5b59e9b] check-in: [5358e9ea6a] user: js, branch: trunk, size: 7063 [annotate] [blame] [check-ins using] [diff]

2019-03-08
00:35
Use dot syntax file: [fde76d6a75] check-in: [bceb7ed4c9] user: js, branch: trunk, size: 7067 [annotate] [blame] [check-ins using] [diff]
2019-02-17
22:16
OFWindowsRegistryKey: Add write support file: [168ff4f79b] check-in: [4c5f686a52] user: js, branch: trunk, size: 7069 [annotate] [blame] [check-ins using] [diff]
2019-01-03
19:13
Update copyright file: [9c72a41f8e] check-in: [0509d7a844] user: js, branch: trunk, size: 6542 [annotate] [blame] [check-ins using] [diff]
2018-07-28
18:45
Rename OFLocalization -> OFLocale file: [ea81330206] check-in: [aa0384d1bf] user: js, branch: trunk, size: 6536 [annotate] [blame] [check-ins using] [diff]
2018-04-08
18:18
Make usage of several _Unwind_* functions optional

This removes the special casing for Itanium and makes compilation on
OpenBSD/SPARC64 work with clang. file: [7a9ee871b5] check-in: [879e69dd3d] user: js, branch: trunk, size: 6560 [annotate] [blame] [check-ins using] [diff]

2018-01-03
19:49
Update copyright notice file: [4b731d03ec] check-in: [7e5c81e186] user: js, branch: trunk, size: 7074 [annotate] [blame] [check-ins using] [diff]
2017-10-17
00:33
Do not use implicit method return types

Instead, explicitly declare them, as OF_ASSUME_NONNULL_{BEGIN,END} does
not apply to implicit return types. This means that after this commit,
all init methods have a nonnull return type, as they should have. file: [821a0dbd2f] check-in: [2f4e0df8be] user: js, branch: trunk, size: 7051 [annotate] [blame] [check-ins using] [diff]

2017-06-05
17:36
Clean up exceptions a little

This removes several initializers that omitted the errNo. Removing those
forces to think about whether there is a meaningful errNo to set instead
of just omitting it. file: [a4f5d8c32c] check-in: [4f36894ce7] user: js, branch: trunk, size: 7037 [annotate] [blame] [check-ins using] [diff]

2017-05-07
21:17
Use generic for -[OFException backtrace] file: [254309bfd5] check-in: [70adcc7bdd] user: js, branch: trunk, size: 6992 [annotate] [blame] [check-ins using] [diff]
20:10
Small code style change

Casts are now written like types in variable declarations. file: [0b126c90fd] check-in: [4af49a13c3] user: js, branch: trunk, size: 6941 [annotate] [blame] [check-ins using] [diff]

2017-04-02
01:06
Add OF_CONSTRUCTOR() / OF_DESTRUCTOR() file: [8fabc728f2] check-in: [d07c56a8bb] user: js, branch: trunk, size: 6923 [annotate] [blame] [check-ins using] [diff]
2017-03-12
02:34
Handle strerror_r being different with _GNU_SOURCE file: [860e2e36ac] check-in: [ff538c8d26] user: js, branch: trunk, size: 6962 [annotate] [blame] [check-ins using] [diff]
2017-01-09
17:36
Update copyright

Forgot to add 2017, even though I already did quite some changes in
2017. file: [681ad6119e] check-in: [44f45c2e35] user: js, branch: trunk, size: 6626 [annotate] [blame] [check-ins using] [diff]

06:26
Add OFLocalization

This singleton gives access to all things locale, including the ability
to get localized strings.

This also adds the OF_LOCALIZED() macro. Its first argument is an ID for
the string to be localized and its second argument is the fallback
string to be used if it cannot retrieve the localized string. Following
that are variable name / value pairs to be replaced in the localized
string.

Getting translated strings is not implemented yet: Instead, it always
uses the fallback string.

This also switches ofhttp to localized strings. file: [9a85916e30] check-in: [06bcb21fc7] user: js, branch: trunk, size: 6620 [annotate] [blame] [check-ins using] [diff]

2016-06-08
23:05
Don't use ARM EHABI if __ARM_DWARF_EH__ is defined file: [a913b4b6a3] check-in: [d55f62409f] user: js, branch: trunk, size: 6634 [annotate] [blame] [check-ins using] [diff]
2016-02-21
15:37
Make use of C99-style for loops file: [cf73e10b2d] check-in: [e0b9167693] user: js, branch: trunk, size: 6501 [annotate] [blame] [check-ins using] [diff]
2016-01-05
22:00
(u)int_fast*_t -> (u)int*_t

(U)INT_FAST*_MAX is broken on Android, which makes (u)int_fast*_t
dangerous to use while it does not provide any real speed benefit. file: [79bfb21fe1] check-in: [d3158d091f] user: js, branch: trunk, size: 6500 [annotate] [blame] [check-ins using] [diff]

2016-01-03
00:43
Update copyright

While at it, also update the mail address. file: [be5e01d81a] check-in: [cec0f072f8] user: js, branch: 0.8, size: 6556 [annotate] [blame] [check-ins using] [diff]

00:41
Update copyright

While at it, also update the mail address. file: [3ce36007c3] check-in: [2a27cf3000] user: js, branch: trunk, size: 6510 [annotate] [blame] [check-ins using] [diff]

2015-10-19
22:15
Add platform.h & make platform defines consistent file: [ef5117f29b] check-in: [1ba08eebc5] user: js, branch: trunk, size: 6506 [annotate] [blame] [check-ins using] [diff]
2015-05-14
09:34
OFException.m: Fix missing includes

Some systems declare strerror() and strerror_r() in string.h, others in
stdio.h. file: [ca1be9d395] check-in: [dddeff64f8] user: js, branch: trunk, size: 6552 [annotate] [blame] [check-ins using] [diff]

2015-03-30
21:32
OFException: Fix missing #ifdef / #endif file: [35e676e981] check-in: [4d16add5ae] user: js, branch: trunk, size: 6513 [annotate] [blame] [check-ins using] [diff]
2015-02-16
08:39
Explicitly pass errno to exceptions

The old behaviour where the exception would access errno directly on
creation of the exception was very fragile. The two main problems with
it were that sometimes it would pick up an errno even though none had
been set and in other cases that when the exception was created errno
had already been overridden.

This also greatly increases errno handling on Win32, especially in
conjunction with sockets. It can still be improved further, though. file: [23bfa51fc4] check-in: [62e2de30b9] user: js, branch: trunk, size: 6477 [annotate] [blame] [check-ins using] [diff]

2015-01-03
20:57
Update copyright file: [f35f997d0d] check-in: [cfd374b906] user: js, branch: trunk, size: 5547 [annotate] [blame] [check-ins using] [diff]
2014-06-21
21:43
Move all macros from OFObject.h to macros.h

This means that OFObject.h imports macros.h now, making it unnecessary
to manually import macros.h in almost every file. And while at it, also
import autorelease.h in OFObject.h, so that this doesn't need to be
manually imported in almost every file as well. file: [fa215236ea] check-in: [13ee56edf3] user: js, branch: trunk, size: 5541 [annotate] [blame] [check-ins using] [diff]

2014-05-15
01:50
Don't define _*_SOURCE

Instead, just define _GNU_SOURCE when __GLIBC__ is defined. After all,
that's the only libc that doesn't work properly without any defines. file: [d55e878757] check-in: [17be12b6e5] user: js, branch: trunk, size: 5566 [annotate] [blame] [check-ins using] [diff]

2014-02-13
23:26
Use -std=c11 instead of -std=gnu11

Not using -std=gnu11 means _GNU_SOURCE does not get defined anymore,
therefore this commit also adds the required feature defines for glibc.

Additionally, this adds of_strdup in macros.h, as strdup is an
extension. file: [daa1364182] check-in: [2f5af58573] user: js, branch: trunk, size: 5587 [annotate] [blame] [check-ins using] [diff]

2014-02-12
15:36
Add support for SEH exceptions

Does not work yet due to a GCC bug. I already found the bug and also
have a fix for it, but it needs to get upstreamed. file: [5e0042a4d3] check-in: [d7883de826] user: js, branch: trunk, size: 5587 [annotate] [blame] [check-ins using] [diff]

03:17
Fix compilation with mingw-w64 file: [258c074e64] check-in: [6ba4095f05] user: js, branch: trunk, size: 5372 [annotate] [blame] [check-ins using] [diff]
2014-01-04
00:24
Update copyright. file: [d1f66eef49] check-in: [3b97fc3cd9] user: js, branch: trunk, size: 3963 [annotate] [blame] [check-ins using] [diff]
2013-12-14
02:22
OFException: Don't redefine HAVE_DWARF_EXCEPTIONS. file: [8fa4d41c68] check-in: [60922fdb15] user: js, branch: trunk, size: 3957 [annotate] [blame] [check-ins using] [diff]
2013-12-10
01:47
Ignore OBJC_ZEROCOST_EXCEPTIONS on ARM.

It seems to be defined when targeting 32-bit iOS, even though it does
not use zero-cost exceptions. file: [6a81d34ff8] check-in: [65d8a7c8ed] user: js, branch: trunk, size: 3917 [annotate] [blame] [check-ins using] [diff]

2013-12-01
11:51
OFException: Do not show <??+offset>.

The offset is useless if the symbol is unknown, especially if it gets
large because the offset is relative to 0. file: [76191c1054] check-in: [353b3ba81d] user: js, branch: trunk, size: 3773 [annotate] [blame] [check-ins using] [diff]

2013-08-25
20:42
Fix backtraces when using the Apple runtime. file: [03e1d50c2c] check-in: [0e854d19bf] user: js, branch: trunk, size: 3640 [annotate] [blame] [check-ins using] [diff]
2013-08-20
19:03
Only use _Unwind_Backtrace() if we have DWARF EH. file: [9b10a5e2e6] check-in: [2bdac84cf3] user: js, branch: trunk, size: 3511 [annotate] [blame] [check-ins using] [diff]
2013-07-05
20:02
Warn if atomic ops AND spinlocks are missing. file: [84994201ec] check-in: [2db4aee23f] user: js, branch: trunk, size: 3376 [annotate] [blame] [check-ins using] [diff]
16:54
Map WSA error codes to standard error codes. file: [bf88fcb9d3] check-in: [e790f0e1f0] user: js, branch: trunk, size: 3342 [annotate] [blame] [check-ins using] [diff]
2013-06-30
19:13
configure: Check for dladdr(). file: [ab1bc6e29e] check-in: [e0f421b523] user: js, branch: trunk, size: 2808 [annotate] [blame] [check-ins using] [diff]
2013-06-25
20:31
Make backtraces work with ARM EABI. file: [e70ae26647] check-in: [6e8777fc03] user: js, branch: trunk, size: 2809 [annotate] [blame] [check-ins using] [diff]
2013-06-22
12:12
Rework exceptions.

This mostly removes the argument for the class in which the exception
occurred. As backtraces were recently added for all platforms, the
passed class does not give any extra information on where the exception
occurred anymore.

This also removes a few other arguments which were not too helpful. In
the past, the idea was to pass as many arguments as possible so that it
is easier to find the origin of the exception. However, as backtraces
are a much better way to find the origin, those are not useful anymore
and just make the exception more cumbersome to use. The rule is now to
only pass arguments that might help in recovering from the exception or
provide information that is otherwise not easily accessible. file: [ef6fdedc48] check-in: [3d16a30f41] user: js, branch: trunk, size: 2520 [annotate] [blame] [check-ins using] [diff]

2013-06-12
20:12
OFException.m: Define _GNU_SOURCE. file: [48e20b7662] check-in: [e4cb03d080] user: js, branch: trunk, size: 2803 [annotate] [blame] [check-ins using] [diff]
2013-06-11
22:55
Use _Unwind_Backtrace() to get a backtrace.

With this, neither the buggy __builtin_return_address() nor the GNU-only
backtrace() are required for a backtrace. file: [59da75fa7e] check-in: [259f593244] user: js, branch: trunk, size: 2782 [annotate] [blame] [check-ins using] [diff]

2013-06-03
21:38
OFException: Cleaner way to check architecture. file: [d08e1839ba] check-in: [42ed7e394c] user: js, branch: trunk, size: 3783 [annotate] [blame] [check-ins using] [diff]
2013-05-25
11:40
Switch back to backtrace().

The reason is that __builtin_frame_address(n) for n > 0 seems to just
crash on most platforms when -fomit-stack-pointer is specified, which
seems to be the default for many platforms on -O2. The documentation
says that __builtin_frame_address() should return NULL in case it can't
get the frame, but it seems to crash instead.

Therefore, this commit reverts to using backtrace() from execinfo.h, if
available. However, as __builtin_frame_address() seems to always work on
PPC (even with -fomit-frame-pointer) and seems to be the only way to get
a backtrace on the Wii, this is still used if backtrace() is unavailable
and __ppc__ defined. file: [fbd2e39b2b] check-in: [f2a8bdf254] user: js, branch: trunk, size: 3823 [annotate] [blame] [check-ins using] [diff]

2013-05-22
20:36
Don't depened on execinfo.h for backtraces.

Instead, __builtin_return_address() is used now. This makes backtraces
available on many platforms, it even works if dladdr is missing (it does
not show symbol names then, though). file: [18d7beaf46] check-in: [a889f21180] user: js, branch: trunk, size: 3039 [annotate] [blame] [check-ins using] [diff]

2013-05-08
20:15
Add -[OFException backtrace]. file: [122354a46f] check-in: [41716f97ed] user: js, branch: trunk, size: 2167 [annotate] [blame] [check-ins using] [diff]
2013-02-13
23:10
Don't cache the description of exceptions.

This was pretty pointless, as it's usually only used once. file: [5040476f6b] check-in: [d9ddc4d06e] user: js, branch: trunk, size: 1209 [annotate] [blame] [check-ins using] [diff]

2013-02-12
18:22
Prefix all ivars with an underscore. file: [0dacb298b3] check-in: [e40729d406] user: js, branch: trunk, size: 1361 [annotate] [blame] [check-ins using] [diff]
2013-02-05
22:24
Move abort() to make old GCCs happy. file: [17d551971c] check-in: [737a82e1a4] user: js, branch: trunk, size: 1357 [annotate] [blame] [check-ins using] [diff]
2013-01-09
22:24
Update copyright. file: [e208f6621b] check-in: [813c00ccf0] user: js, branch: trunk, size: 1357 [annotate] [blame] [check-ins using] [diff]
2012-12-22
15:37
Add -[doesNotRecognizeSelector:]. file: [e32d14537c] check-in: [917ce5754c] user: js, branch: trunk, size: 1351 [annotate] [blame] [check-ins using] [diff]
2012-10-09
15:07
Make use of instancetype. file: [2112dc5f17] check-in: [fb515e8e24] user: js, branch: trunk, size: 1383 [annotate] [blame] [check-ins using] [diff]
2012-09-17
09:30
Simplify autoreleasing. file: [32b20ebef7] check-in: [c9bea2982f] user: js, branch: trunk, size: 1369 [annotate] [blame] [check-ins using] [diff]
2012-07-12
01:28
Don't access isa directly. file: [e04692d9ff] check-in: [8892ae9fcc] user: js, branch: trunk, size: 1368 [annotate] [blame] [check-ins using] [diff]
2012-06-17
22:47
Better description for OFException. file: [13ae2563a0] check-in: [28ed6c344a] user: js, branch: trunk, size: 1336 [annotate] [blame] [check-ins using] [diff]
2012-01-05
00:56
Update copyright. file: [edd904354d] check-in: [ce70e17b38] user: js, branch: trunk, size: 1181 [annotate] [blame] [check-ins using] [diff]
2011-09-22
23:25
Exceptions are now autoreleased.

This is safe as an "exception loop" can't happen, since if allocating
an exception fails, it throws an OFAllocFailedException which is
preallocated and can always be thrown.

So, the worst case would be that an autorelease of an exception fails,
triggering an OFOutOfMemoryException for which there is no memory,
resulting in an OFAllocFailedException to be thrown. file: [77fce54f87] check-in: [e1e7ffa903] user: js, branch: trunk, size: 1175 [annotate] [blame] [check-ins using] [diff]

2011-03-24
16:09
Added: Split OFExceptions.{h,m} into one file per exception. file: [d023c56c3e] check-in: [e1eea29286] user: js, branch: trunk, size: 1250 [annotate] [blame] [check-ins using]