blob: 3c7c6d80fb9a6dea4333a10ecc199142e0626294 [file] [log] [blame]
Zesstra7ea4a032019-11-26 20:11:40 +01001SYNOPSIS
2 #include <sys/driver_hooks.h>
3
4 set_driver_hook(H_FILE_ENCODING, value)
5
6 <value> being:
7
8 string <text>
9 string <closure>(string filename)
10
11DESCRIPTION
12 Optonal hook specifying the name of the encoding to be used
13 for decoding a file. Hook setting can be a string or a closure.
14
15 If no hook was specified or the closure returns 0, then the
16 default "ascii" is used (and thus will throw an error upon
17 chars greater than 0x7f in the file).
18
19 If the settings is a closure, it will be called for every file
20 opened by the compiler or by read_file() and write_file()
21 (unless an explicit encoding was given).
22
23HISTORY
24 Introduced in LDMud 3.5.1
25
26SEE ALSO
27 hooks(C)