AI agent instruction updates#13335
Open
bneradt wants to merge 1 commit into
Open
Conversation
moonchen
reviewed
Jun 25, 2026
7828aaf to
11fbce8
Compare
11fbce8 to
c6e5a47
Compare
AI coding guidance does not fully reflect project conventions, which can lead agents toward inconsistent names and less maintainable tests. This aligns the instructions with established AuTest, Python, and C++ practices. It also documents both private-member prefix styles and the community preference for `_` in new files.
c6e5a47 to
a168946
Compare
Comment on lines
+319
to
+323
| - Private member variables use both `_` and `m_` prefixes in the source code; | ||
| be consistent with the surrounding code. For new files, prefer the `_` prefix | ||
| because that reflects the community consensus. | ||
| - Boolean variables and functions returning boolean values are named as | ||
| predicates: use `was_modified` rather than `modified`. |
Contributor
Author
There was a problem hiding this comment.
Also, recommending leading-underscore names in new code is risky because leading underscores can be reserved in some contexts.
Yeah, you and I lost that argument. The community prefers _ prefixes for private variables.
Contributor
There was a problem hiding this comment.
It seems identifiers with leading _ prefixes followed by lowercase letters are only reserved if they have external linkage.
Contributor
Author
There was a problem hiding this comment.
Thanks for the reference.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A few tweaks for guiding AI agents.
Undraft this after @moonchen 's similar updates land and this is merged with those changes:
#13306