all: fix typos (#24470)

This commit is contained in:
omahs 2025-05-13 21:05:22 +02:00 committed by GitHub
parent 0a37c22e4f
commit 1957162c2a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
25 changed files with 52 additions and 52 deletions

View File

@ -284,7 +284,7 @@
- Fix msvc build filename, remove temp files (#23890)
- Improve the stability of generated code for auto string methods
- Fix codegen for array of anon struct (fix #23896) (#23907)
- Make sure to call the overriden `pub fn (mut a []string) free() {` method, NOT the generic `fn (a &array) free() {` one. (#23911)
- Make sure to call the overridden `pub fn (mut a []string) free() {` method, NOT the generic `fn (a &array) free() {` one. (#23911)
- Fix generic container init (fix #23910) (#23912)
- Fix codegen for generic structinit and generic array return (fix #23916) (#23943)
- Implement alias operator overloading for generic struct parent type (fix #23965) (#23967)
@ -1188,7 +1188,7 @@
- net.http: implement http.download_file_with_progress/2, saving each chunk, as it is received, without growing the memory usage (#21633)
- veb: update import name in docs (#21668)
- Add `m3u8` MIME type `application/vnd.apple.mpegurl` for multimedia playlists (#21688)
- veb.auth: use constant time comparision in compare_password_with_hash (#21693)
- veb.auth: use constant time comparison in compare_password_with_hash (#21693)
- net.http: correct `Response.status()` method comment, to indicate returning of a `Status` enum field, instead of struct (#21735)
- net: fix TcpConn.peer_ip/0 to only return the ip address, without the port number (#21831)
- Add mime type `text/x-vlang`, for `.v` and `.vsh` file extensions (#21851)

View File

@ -11,37 +11,37 @@ fn a3()
fn a4()
This should be merged into one paragraph.
Note: this should be it's own paragraph.
Note: this should be its own paragraph.
fn a5()
This should be its own paragraph.
Note: this should also be it own paragraph
Note: this should be it's own paragraph.
Note: this should be its own paragraph.
fn a6()
A comment
Fixme: this should be it's own paragraph.
Fixme: this should be its own paragraph.
Fixme: this should be it's own paragraph.
Fixme: this should be its own paragraph.
Fixme: this should be it's own paragraph.
Fixme: this should be its own paragraph.
fn a7()
A comment
Todo: this should be it's own paragraph.
Todo: this should be its own paragraph.
Todo: this should be it's own paragraph.
Todo: this should be its own paragraph.
Todo: this should be it's own paragraph.
Todo: this should be its own paragraph.
fn a8()
A comment
Todo: this should be it's own paragraph.
Todo: this should be its own paragraph.
Note: this should be it's own paragraph.
Note: this should be its own paragraph.
Fixme: this should be it's own paragraph.
Fixme: this should be its own paragraph.
fn a9()
normal comment
fn foo()

View File

@ -18,38 +18,38 @@ pub fn a3() {
// This should be merged
// into one paragraph.
// Note: this should be it's own paragraph.
// Note: this should be its own paragraph.
pub fn a4() {
println('hi')
}
// This should be its own paragraph.
// NOTE: this should also be it own paragraph
// note: this should be it's own paragraph.
// note: this should be its own paragraph.
pub fn a5() {
println('hi')
}
// A comment
// Fixme: this should be it's own paragraph.
// fixme: this should be it's own paragraph.
// FIXME: this should be it's own paragraph.
// Fixme: this should be its own paragraph.
// fixme: this should be its own paragraph.
// FIXME: this should be its own paragraph.
pub fn a6() {
println('hi')
}
// A comment
// TODO: this should be it's own paragraph.
// todo: this should be it's own paragraph.
// Todo: this should be it's own paragraph.
// TODO: this should be its own paragraph.
// todo: this should be its own paragraph.
// Todo: this should be its own paragraph.
pub fn a7() {
println('hi')
}
// A comment
// TODO: this should be it's own paragraph.
// NOTE: this should be it's own paragraph.
// FIXME: this should be it's own paragraph.
// TODO: this should be its own paragraph.
// NOTE: this should be its own paragraph.
// FIXME: this should be its own paragraph.
pub fn a8() {
println('hi')
}

View File

@ -212,7 +212,7 @@ fn (upd VlsUpdater) download_prebuilt() ! {
}
if has_last_updated_at && !upd.is_force && asset_last_updated_at <= last_updated_at {
upd.log("VLS was already updated to it's latest version.")
upd.log('VLS was already updated to its latest version.')
return
}
@ -265,7 +265,7 @@ fn (upd VlsUpdater) compile_from_source() ! {
upd.log('Updating VLS repo...')
pull_result := os.execute('${os.quoted_path(vexe)} retry -- ${git} -C ${vls_src_folder} pull')
if !upd.is_force && pull_result.output.trim_space() == 'Already up to date.' {
upd.log("VLS was already updated to it's latest version.")
upd.log('VLS was already updated to its latest version.')
return
}
}

View File

@ -342,7 +342,7 @@ fn reduce_scope(content string, error_msg string, command string, do_fmt bool, f
outer_modified_smth = true
println('')
show_code_stats(code)
} else { // if can remove it, no need to go though it's children
} else { // if can remove it, no need to go through its children
for i in 0 .. item.children.len {
stack.insert(0, &item.children[i]) // breadth first search
}
@ -421,7 +421,7 @@ fn reduce_scope(content string, error_msg string, command string, do_fmt bool, f
outer_modified_smth = true
println('')
show_code_stats(code)
} else { // if can remove it, can remove it's children
} else { // if can remove it, can remove its children
for i in 0 .. item.children.len {
stack << &item.children[i]
}

View File

@ -5,7 +5,7 @@
// vshader aids in generating special shader code C headers via sokol-shdc's 'annotated GLSL' format to any
// supported target formats that sokol_gfx supports internally.
//
// vshader bootstraps itself by downloading it's own dependencies to a system cache directory on first run.
// vshader bootstraps itself by downloading its own dependencies to a system cache directory on first run.
//
// Please see https://github.com/floooh/sokol-tools/blob/master/docs/sokol-shdc.md#feature-overview
// for a more in-depth overview of the specific tool in use.

View File

@ -62,7 +62,7 @@ fn main() {
exit(0)
} else {
// The process supervisor should NOT crash/panic, unlike the workers.
// It's job, is to:
// Its job, is to:
// 1) start workers
// 2) accumulate results
// 3) produce a summary at the end

View File

@ -6072,7 +6072,7 @@ that are substituted at compile time:
- `@BUILD_TIME` => replaced with the build time, for example '12:32:07' .
- `@BUILD_TIMESTAMP` => replaced with the build timestamp, for example '1726219885' .
Note: `@BUILD_DATE`, `@BUILD_TIME`, `@BUILD_TIMESTAMP` represent times in the UTC timezone.
By default, they are based on the current time of the compilation/build. They can be overriden
By default, they are based on the current time of the compilation/build. They can be overridden
by setting the environment variable `SOURCE_DATE_EPOCH`. That is also useful while making
releases, since you can use the equivalent of this in your build system/script:
`export SOURCE_DATE_EPOCH=$(git log -1 --pretty=%ct) ;` , and then use `@BUILD_DATE` etc.,

View File

@ -7,7 +7,7 @@ import hash
// NID constants
//
// NIST P-256 is refered to as secp256r1 and prime256v1, defined as #define NID_X9_62_prime256v1 415
// NIST P-256 is referred to as secp256r1 and prime256v1, defined as #define NID_X9_62_prime256v1 415
// Different names, but they are all the same.
// https://www.rfc-editor.org/rfc/rfc4492.html#appendix-A
const nid_prime256v1 = C.NID_X9_62_prime256v1

View File

@ -62,7 +62,7 @@ fn test_raw_indexing() {
assert utf8.raw_index(a, 7) == 'g'
assert utf8.raw_index(a, 8) == '!'
// test differnt utf8 byte lenghts
// test differnt utf8 byte lengths
c := 'a©🚀'
assert utf8.raw_index(c, 0) == 'a' // 1 byte
assert utf8.raw_index(c, 1) == '©' // 2 bytes

View File

@ -108,7 +108,7 @@ fn do_work() {
### Notes:
1. Each `EventBus` instance has it's own registry (i.e. there is no global event registry
1. Each `EventBus` instance has its own registry (i.e. there is no global event registry
so you can't just subscribe to an event wherever you are.
2. Each `EventBus` has a `Subscriber` instance which will need to be either exposed or you can make
small public helper functions specific to your module like (`onPress`, `onError`) and etc.

View File

@ -22,7 +22,7 @@ pub fn debugger_present() bool {
// no external debugger
exit(0)
} else {
// an error occured, a external debugger must be present
// an error occurred, a external debugger must be present
exit(1)
}
} else {

View File

@ -21,7 +21,7 @@ pub fn debugger_present() bool {
// no external debugger
exit(0)
} else {
// an error occured, a external debugger must be present
// an error occurred, a external debugger must be present
exit(1)
}
} else {

View File

@ -25,7 +25,7 @@ pub fn debugger_present() bool {
// no external debugger
exit(0)
} else {
// an error occured, a external debugger must be present
// an error occurred, a external debugger must be present
exit(1)
}
} else {

View File

@ -211,7 +211,7 @@ mut:
b int // private mutable
c int // (you can list multiple fields with the same access modifier)
pub:
d int // public immmutable (readonly)
d int // public immutable (readonly)
pub mut:
e int // public, but mutable only in parent module
f int // public and mutable both inside and outside parent module

View File

@ -148,7 +148,7 @@ pub fn (t &ResolverInfo) get_ct_type_var(node ast.Expr) ast.ComptimeVarKind {
return .no_comptime
}
// get_type_from_comptime_var retrives the comptime type related to $for variable
// get_type_from_comptime_var retrieves the comptime type related to $for variable
@[inline]
pub fn (t &TypeResolver) get_type_from_comptime_var(var ast.Ident) ast.Type {
match var.name {

View File

@ -3,7 +3,7 @@ import os
fn test_githash() {
if os.getenv('GITHUB_JOB') == '' {
eprintln('> skipping test, since it needs GITHUB_JOB to be defined (it is flaky on development machines, with changing repos and v compiled with `./v self` from uncommited changes).')
eprintln('> skipping test, since it needs GITHUB_JOB to be defined (it is flaky on development machines, with changing repos and v compiled with `./v self` from uncommitted changes).')
return
}
if !os.exists(os.join_path(@VMODROOT, '.git')) {

View File

@ -6,7 +6,7 @@ module util
import os
import v.vmod
// resolve_vmodroot replaces all occurences of `@VMODROOT` in `str`, with an absolute path,
// resolve_vmodroot replaces all occurrences of `@VMODROOT` in `str`, with an absolute path,
// formed by resolving, where the nearest `v.mod` is, given the folder `dir`.
pub fn resolve_vmodroot(str string, dir string) !string {
mut mcache := vmod.get_cache()

View File

@ -124,7 +124,7 @@ pub fn (mut s Scanner) scan() token.Token {
s.offset++
// NOTE: I have made `@[` a token instead of using `@` and `[` because `@`
// is not currently used as a token, and it is also easier to parse this way.
// if/when `@` becomes used as a token of it's own, then I may change this.
// if/when `@` becomes used as a token of its own, then I may change this.
if c == `@` && s.src[s.offset] == `[` {
s.offset++
return .attribute

View File

@ -411,7 +411,7 @@ fn handle_read[A, X](mut pv picoev.Picoev, mut params RequestParams, fd int) {
eprintln('[veb] error reading request body: ${err}')
if err is io.Eof {
// we expect more data to be send, but an Eof error occured, meaning
// we expect more data to be send, but an Eof error occurred, meaning
// that there is no more data to be read from the socket.
// And at this point we expect that there is data to be read for the body.
fast_send_resp(mut conn, http.new_response(

View File

@ -437,7 +437,7 @@ pub fn (mut c Cipher) set_counter(ctr u64) {
// rekey resets internal Cipher's state and reinitializes state with the provided key and nonce
pub fn (mut c Cipher) rekey(key []u8, nonce []u8) ! {
unsafe { c.reset() }
// this routine was publicly accesible to user, so we add a check here
// this routine was publicly accessible to user, so we add a check here
// to ensure the supplied key and nonce has the correct size.
if key.len != key_size {
return error('Bad key size provided for rekey')

View File

@ -1,6 +1,6 @@
This `slhdsa` module requires latest OpenSSL library and development headers.
It required minimum of OpenSLL 3.5 version.
Likely most of the linux (unix) distros does not ships with this version on this time
Likely most of the linux (unix) distros do not ship with this version on this time
of writing, at March, 2025.
You can manually download and install OpenSSL library by your self. This documents acts as a simple
@ -23,7 +23,7 @@ $ ./Configure --prefix=/opt/ssl --openssldir=/opt/ssl
$ make
$ sudo make install
```
By succesfully this step, the latest OpenSSL has been built and installed onto
By successfully completing this step, the latest OpenSSL has been built and installed onto
configured path. You need to tell the system to add this path. <br>
4. Add `/opt/ssl/lib64` entry onto `/etc/ld.so.conf.d/libcrypto.conf`

View File

@ -100,7 +100,7 @@ pub fn (pv PrivateKey) dump_key() !string {
return output
}
// public_key gets the the public part of this private key as a PublicKey.
// public_key gets the public part of this private key as a PublicKey.
pub fn (pv PrivateKey) public_key() !PublicKey {
pbkey := C.EVP_PKEY_dup(pv.key)
// we clears out the private bits from the key

View File

@ -197,7 +197,7 @@ pub fn (v Integer) payload() ![]u8 {
// - The integer value contains the encoded integer if it is positive, or its two's complement if it is negative.
// - If the integer is positive but the high order bit is set to 1, a leading 0x00 is added to the content
// to indicate that the number is not negative.
// - If the number is negative after applying two's-complement rules, and the the most-significant-bit of the
// - If the number is negative after applying two's-complement rules, and the most-significant-bit of the
// the high order bit of the bytes results isn't set, pad it with 0xff in order to keep the number negative.
fn (v Integer) pack_into_twoscomplement_form() !([]u8, int) {
match v.value {
@ -226,7 +226,7 @@ fn (v Integer) pack_into_twoscomplement_form() !([]u8, int) {
}
-1 {
// A negative number has to be converted to two's-complement form.
// by invert the number and and then subtract it with big(1), or with other mean
// by invert the number and then subtract it with big(1), or with other mean
// Flip all of the bits in the value and then add one to the resulting value.
// If the most-significant-bit isn't set then we'll need to pad the
// beginning with 0xff in order to keep the number negative.

View File

@ -553,15 +553,15 @@ fn (mut decoder Decoder) decode_value[T](mut val T) ! {
string_info := decoder.current_node.value
if string_info.value_kind == .string_ {
buffer_lenght, escape_positions := decoder.calculate_string_space_and_escapes()!
buffer_length, escape_positions := decoder.calculate_string_space_and_escapes()!
string_buffer := []u8{cap: buffer_lenght}
string_buffer := []u8{cap: buffer_length}
if escape_positions.len == 0 {
if string_info.length != 0 {
unsafe {
string_buffer.push_many(decoder.json.str + string_info.position + 1,
buffer_lenght)
buffer_length)
}
}
} else {