returning optional issues test

This commit is contained in:
koniifer 2024-11-06 15:17:03 +00:00
parent d3ee72306e
commit d2ba7cc101
2 changed files with 19 additions and 0 deletions

View file

@ -626,6 +626,24 @@ main := fn(): uint {
}
```
#### returning_optional_issues
```hb
BMP := 0
get_format := fn(): ?uint {
return BMP
}
main := fn(): uint {
fmt := get_format()
if fmt == null {
return 1
} else {
return fmt
}
}
```
#### inlining_issues
```hb
main := fn(): void {

View file

@ -4595,5 +4595,6 @@ mod tests {
overwrite_aliasing_overoptimization;
more_if_opts;
optional_from_eca;
returning_optional_issues;
}
}