Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@AbdullinAM
Copy link
Member

Basic implementation of #4065.

Adding a new TagWrapper is also an API breaking change. Another way around this is to basically have the logic from KdocMarkdowsParser implemented in the DescriptorSections. I think it makes sense to have this logic on the "documentable model" side, but I don't have a strong opinion here.

If we want to go with this implementation, probably we also need to update IDE to have similar behaviour.

Copy link
Contributor

@vmishenev vmishenev left a comment

Choose a reason for hiding this comment

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

Another way around this is to basically have the logic from KdocMarkdowsParser implemented in the DescriptorSections. I think it makes sense to have this logic on the "documentable model" side

As for me, the current approach is okay. In DescriptorSections, we would need to calculate what a parameter is.

|/src/main/kotlin/test/source.kt
|package test
| /**
| * @param[this] receiver
Copy link
Contributor

Choose a reason for hiding this comment

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

Should @param[this] be allowed?
The KEEP: Streamline ambiguous KDoc links explicitly prohibit this case.

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't think we explicitly agreed on this. It was discussed in #4065, I implemented it here as a 'test' to get feedback on do we really want this behaviour

customTagSectionContent(d, sourceSets, customTagContentProviders)
unnamedTagSectionContent(d, sourceSets) { toHeaderString() }

contextParamsSectionContent(tags)
Copy link
Contributor

Choose a reason for hiding this comment

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

Have we decided to have a separate section? Should QDoc do the same?

Copy link
Member Author

Choose a reason for hiding this comment

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

It was mentioned by @whyoleg during our discussion. And in general, I think it is the whole idea of #4065. Otherwise, context parameters work correctly now.

My suggestion is to sync with IDE so that QDoc shows the smae

Copy link
Contributor

@vmishenev vmishenev Dec 19, 2025

Choose a reason for hiding this comment

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

In this case, should we separate the parameters of a function/constructor from the type parameters as well?

Copy link
Member Author

Choose a reason for hiding this comment

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

That makes sense, we can do that too. @whyoleg wdyt?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants