aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-07-05 16:26:11 +0100
committergingerBill <bill@gingerbill.org>2021-07-05 16:26:11 +0100
commit3b9ca8535fda8d6dc1677d3bd063b7d9ddf160e5 (patch)
treeaad62cff2c8179700fe610e9be731dff1061964b
parenta98eee145d60a42324835c578d8573675d6fdd49 (diff)
Fix comments
-rw-r--r--examples/demo/demo.odin6
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/demo/demo.odin b/examples/demo/demo.odin
index eaa8454b3..123f56fce 100644
--- a/examples/demo/demo.odin
+++ b/examples/demo/demo.odin
@@ -2003,7 +2003,7 @@ or_else_procedure :: proc() {
fmt.println("\n#'or_else'");
// IMPORTANT NOTE: 'or_else' is experimental features and subject to change/removal
{
- // 'try else' does a similar value check as 'try' but instead of doing an
+ // 'or_else' does a similar value check as 'try' but instead of doing an
// early return, it will give a default value to be used instead
m: map[string]int;
@@ -2013,13 +2013,13 @@ or_else_procedure :: proc() {
if i, ok = m["hellope"]; !ok {
i = 123;
}
- // The above can be mapped to 'try else'
+ // The above can be mapped to 'or_else'
i = or_else(m["hellope"], 123);
assert(i == 123);
}
{
- // 'try else' can be used with type assertions too, as they
+ // 'or_else' can be used with type assertions too, as they
// have optional ok semantics
v: union{int, f64};
i: int;