# std.Build: fix wrong variable used in \`parseTargetQuery\` · gitcafe/zig

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

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

Visibility: public

Requested revision: c280811d1d5b5d73e1eb4243c577f86375447e99

Requested commit: c280811d1d5b5d73e1eb4243c577f86375447e99

Commit: c280811d1d5b5d73e1eb4243c577f86375447e99

Tree: 976d7251aaf651c37415789bebef491c5b5c235e

Author: tjog

Committer: Andrew Kelley

## Message

```
std.Build: fix wrong variable used in `parseTargetQuery`

Also address clobbering diagnostics field with an assert and
doc comment to use the Target.Query.parse function themselves.

Fixes #18876

```

## Parents

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

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