Skip to content

Commit efcb15d

Browse files
authored
docs: update deprecated function results (#18850)
1 parent 52a055b commit efcb15d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

doc/docs.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4551,9 +4551,9 @@ If a test function has an error return type, any propagated errors will fail the
45514551
```v
45524552
import strconv
45534553
4554-
fn test_atoi() ? {
4555-
assert strconv.atoi('1')? == 1
4556-
assert strconv.atoi('one')? == 1 // test will fail
4554+
fn test_atoi() ! {
4555+
assert strconv.atoi('1')! == 1
4556+
assert strconv.atoi('one')! == 1 // test will fail
45574557
}
45584558
```
45594559

@@ -6738,7 +6738,7 @@ fn sh(cmd string) {
67386738
rmdir_all('build') or {}
67396739
67406740
// Create build/, never fails as build/ does not exist
6741-
mkdir('build')?
6741+
mkdir('build')!
67426742
67436743
// Move *.v files to build/
67446744
result := execute('mv *.v build/')
@@ -6749,7 +6749,7 @@ if result.exit_code != 0 {
67496749
sh('ls')
67506750
67516751
// Similar to:
6752-
// files := ls('.')?
6752+
// files := ls('.')!
67536753
// mut count := 0
67546754
// if files.len > 0 {
67556755
// for file in files {

0 commit comments

Comments
 (0)