mirror of
https://github.com/vlang/v.git
synced 2025-08-04 02:07:28 -04:00
vlib: fix typos (endianess
-> endianness
) (#21099)
This commit is contained in:
parent
b01e091473
commit
2db9c82d26
@ -129,7 +129,7 @@ fn decode_from_buffer(dest &u8, src &u8, src_len int) int {
|
||||
u8(index[d[si + 2]]), u8(index[d[si + 3]]), u8(index[d[si + 4]]), u8(index[d[si + 5]]),
|
||||
u8(index[d[si + 6]]), u8(index[d[si + 7]]))
|
||||
|
||||
// Reading out the individual bytes from the u64. Watch out with endianess.
|
||||
// Reading out the individual bytes from the u64. Watch out with endianness.
|
||||
$if little_endian {
|
||||
b[n_decoded_bytes + 0] = datablock_64.data_byte[7]
|
||||
b[n_decoded_bytes + 1] = datablock_64.data_byte[6]
|
||||
|
@ -303,10 +303,10 @@ fn (mut g JsGen) comptime_if_to_ifdef(name string, is_comptime_option bool) !str
|
||||
}
|
||||
// endianness:
|
||||
'little_endian' {
|
||||
return '(\$os.endianess == "LE")'
|
||||
return '(\$os.endianness == "LE")'
|
||||
}
|
||||
'big_endian' {
|
||||
return '(\$os.endianess == "BE")'
|
||||
return '(\$os.endianness == "BE")'
|
||||
}
|
||||
else {
|
||||
if is_comptime_option
|
||||
|
@ -468,7 +468,7 @@ pub fn (mut g JsGen) init() {
|
||||
g.definitions.writeln('}')
|
||||
|
||||
g.definitions.writeln('const \$os = {')
|
||||
g.definitions.writeln(' endianess: "LE",')
|
||||
g.definitions.writeln(' endianness: "LE",')
|
||||
g.definitions.writeln('}')
|
||||
} else {
|
||||
g.definitions.writeln('const \$os = require("os");')
|
||||
|
Loading…
x
Reference in New Issue
Block a user