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

drstring format deletes docstring with this input #192

Closed
dduan opened this issue May 19, 2020 · 0 comments · Fixed by #194
Closed

drstring format deletes docstring with this input #192

dduan opened this issue May 19, 2020 · 0 comments · Fixed by #194

Comments

@dduan
Copy link
Owner

dduan commented May 19, 2020

/// This method will transform any types that are generic or contain generics into Any
/// Will remove any keywords such as escaping, autoclosure, inout
///
/// - parameters type:            The type to normalize
/// - parameters replaceSelfWith: If type == "Self"/"Self?"/"Optional<Self>" will return this value
///                               instead
/// - parameters stripInOut:      Whether or not to strip the inout keyword from the type name
func storedParamType(from type: String, replaceSelfWith: String? = nil, stripInOut: Bool = true) -> String {}

after drstring format it becomes

/// this method will transform any types that are generic or contain generics into any
/// will remove any keywords such as escaping, autoclosure, inout
///
func storedParamType(from type: String, replaceSelfWith: String? = nil, stripInOut: Bool = true) {}
dduan added a commit that referenced this issue May 21, 2020
If a parameter entry is mistakenly prefixed with `- parameters`,
previously we'd see it as a multi-parameter header. Before we proceed to
assign the line to that state, take a look at characters before `:` and
after the keyword. Only proceed as parameter header if there's only
whitespace. Otherwise, try parsing the line again as a parameter entry.

Closes #192.
dduan added a commit that referenced this issue May 21, 2020
If a parameter entry is mistakenly prefixed with `- parameters`,
previously we'd see it as a multi-parameter header. Before we proceed to
assign the line to that state, take a look at characters before `:` and
after the keyword. Only proceed as parameter header if there's only
whitespace. Otherwise, try parsing the line again as a parameter entry.

Closes #192.
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 a pull request may close this issue.

1 participant