# Treat blocks with "return" as "noreturn" · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/135b91aecd9be1f6f5806b667e07e383dd481198)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 135b91aecd9be1f6f5806b667e07e383dd481198

Requested commit: 135b91aecd9be1f6f5806b667e07e383dd481198

Commit: 135b91aecd9be1f6f5806b667e07e383dd481198

Tree: 4bcc701521d344b75b2541ec1347ce2652e020c0

Author: Gregory Anders

Committer: GitHub

## Message

```
Treat blocks with "return" as "noreturn"

Block statements that end with "break" should not be considered
"noreturn" for the enclosing scope, but other "noreturn" instructions
(return, panic, compile error, etc.) should be. This differentiation
necessitates handling "break" differently from the other "noreturn"
instructions when inside a block statement.
```

## Parents

- [33826a6a2e035d2a2be65314ed80a6b7abaf7f12](https://git.cafe/gitcafe/zig/commit/33826a6a2e035d2a2be65314ed80a6b7abaf7f12?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/135b91aecd9be1f6f5806b667e07e383dd481198?format=markdown)
