# stage2: make same line doc comments a parse error · gitcafe/zig

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

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

Visibility: public

Requested revision: 95b95ea33e4b595d2fc6fbea850694b79f27fe55

Requested commit: 95b95ea33e4b595d2fc6fbea850694b79f27fe55

Commit: 95b95ea33e4b595d2fc6fbea850694b79f27fe55

Tree: 7f22d836466700d51acaaf1a943dcdf8dd25f256

Author: Isaac Freund

Committer: Isaac Freund

## Message

```
stage2: make same line doc comments a parse error

Allowing same line doc comments causes some ambiguity as to how
generated docs should represent the case in which both same line
and preceding line doc comments are present:

/// preceding line
const foobar = 42; /// same line

Furthermore disallowing these makes things simpler as there is now only
one way to add a doc comment to a decl or struct field.

```

## Parents

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

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