I have functions which abstract *serial-* and *socket IO* (Linux / Windows) implemented in C.
All of them are marked as `extern "C"` because they may get called from C++ as well.

Is it safe to use `__attribute__((__nothrow__))` (or MinGW Macro `__MINGW_NOTHROW`) here / can i assume no exceptions are thrown?

**Called functions - Sockets:**  

*(not all additions for WinSock listed)*

* `socket`
* `connect`
* `send` / `recv`
* `close` (`closesocket` on Windows)
* `sendto` / `recvfrom`

**Called functions - Serial:**  

*Since serial IO code differs to much between windows / linux not all are listed here*

* *Linux (GNU)*
	+ `open`
	+ `tcgetattr`
	+ `read` / `write`
	+ `close`
* *Windows (MinGW)*
	+ `CreateFile`
	+ `GetCommState` / `SetCommTimeouts`
	+ `ReadFile` / `WriteFile`
	+ `CloseHandle`

Since *ANSI C* has no exceptions (please correct me if I'm wrong) they won't be thrown, but how about GCC extensions and OS API calls?

Documentation: <http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html> (see `nothrow`).