favor return over return _ (void return); newline/closing terminates
This commit is contained in:
@@ -733,8 +733,8 @@
|
||||
(needs string building), struct field defaults to drop `&[]` on empty lists
|
||||
|
||||
29. fix bugs (implemented)
|
||||
- `return _` was already the supported empty return for void functions; the original
|
||||
bare-`return` report was stale
|
||||
- bare `return` is the empty return for void functions; `yield` always requires a
|
||||
same-line, non-void value because `break` handles valueless scope exits
|
||||
- catch value blocks may end by returning from the function instead of yielding when
|
||||
every path exits
|
||||
- implicit-conversion diagnostics render source-level composite and named types instead
|
||||
@@ -834,6 +834,8 @@
|
||||
- add `debug.print` function making use of `std/io` to print values to the console
|
||||
- this may either require native variadic arguments or a tuple value to like zig's approach (consider pros and cons)
|
||||
|
||||
38. consider renaming `ptr_cast` to `ptrcast`
|
||||
|
||||
## A word on unchecked casts
|
||||
|
||||
For casts that bypass safety checks, Honey provides builtin functions:
|
||||
|
||||
Reference in New Issue
Block a user