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

[Feature Request] Relaxing inline doc by allowing ending with "backtick example" #3603

Closed
1 task done
rd4com opened this issue Oct 4, 2024 · 1 comment
Closed
1 task done
Assignees
Labels
Area: Documentation enhancement New feature or request mojo-repo Tag all issues with this label

Comments

@rd4com
Copy link
Contributor

rd4com commented Oct 4, 2024

Review Mojo's priorities

What is your request?

Hello, while creating examples for features (PR),
@JoeLoser noted a possible improvement.

For example:

fn create_list_int() - >List[Int]:
 """Creates a new list of int.
  
 Returns:
  An empty list of `Int`.
 
 Example:
 ```mojo
 def main():
  x = create_list_int()
	```
	Note: can only finish with a dot and not the triple backticks example above.
	"""
 return List[Int]()	

Link to suggestion of @JoeLoser in PR #3593

What is your motivation for this change?

Examples are usually placed after arguments, parameters and return 👍

Any other details?

No response

@rd4com rd4com added enhancement New feature or request mojo-repo Tag all issues with this label labels Oct 4, 2024
@jackos
Copy link
Collaborator

jackos commented Oct 17, 2024

Thanks @rd4com this is fixed as of the latest build

@jackos jackos closed this as completed Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Documentation enhancement New feature or request mojo-repo Tag all issues with this label
Projects
None yet
Development

No branches or pull requests

4 participants