Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Place a warning about the uses of traits in the documentation #10393

Merged
merged 3 commits into from
Jan 16, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/en/reference/limitations-and-known-issues.rst
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,8 @@ core components were designed.
In fact, this documentation mentions traits only in the context of
:doc:`overriding field association mappings in subclasses <tutorials/override-field-association-mappings-in-subclasses>`. Also, the
tests in the ORM codebase (as of writing) cover traits only in two (!) places,
namely the aforementioned override and in an edge-case for the deprecated
"Entity Generator".
namely the aforementioned override and in an edge-case for a tool that will be
removed in Doctrine 3.0.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would replace the whole paragraph with "In fact, traits are rarely mentioned in the docs or in the tests. That way there is no divergence between branches.


Thus, you should at least be aware that when using traits in your entity and
mapped superclasses, you will be in uncharted terrain.
Expand Down