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

RFC: Add description to load a local module and using it in example codes. #41398

Merged
merged 6 commits into from
Feb 12, 2022

Conversation

AtsushiSakai
Copy link
Contributor

I think current Modules doc does not explain how to load a local module and some example codes do not work correctly reported in #40384, because the some example codes do not use local module loading syntax (missing a dot before the module name).

So, I added a description to load a local module and using it in example codes to fix #29302 and to fix #40384.

@AtsushiSakai AtsushiSakai changed the title DOC: Add description to load a local module and using it in example codes. RFC: DOC: Add description to load a local module and using it in example codes. Jun 28, 2021
@vtjnash
Copy link
Sponsor Member

vtjnash commented Jul 2, 2021

Would you be willing to change these to doctests? This should show how to do it: https://juliadocs.github.io/Documenter.jl/stable/man/doctests/#Preserving-Definitions-Between-Blocks which mostly just means changing in the necessary places

```julia

to

```jldoctest nicestuff

@vtjnash vtjnash added the domain:docs This change adds or pertains to documentation label Jul 2, 2021
@vtjnash vtjnash changed the title RFC: DOC: Add description to load a local module and using it in example codes. Add description to load a local module and using it in example codes. Jul 2, 2021
@AtsushiSakai
Copy link
Contributor Author

@vtjnash Thank you for your comment. I changed the related example codes to doctests.
I found some LinearAlgebra.jl doctests failed in my environment, I opened an issue as #41454.
But, the created doctests in this PR works correctly in my environment. PTAL.

@AtsushiSakai AtsushiSakai changed the title Add description to load a local module and using it in example codes. RFC: Add description to load a local module and using it in example codes. Aug 13, 2021
@ViralBShah
Copy link
Member

Let's rebase this to master, and hope that the whitespace check runs through.

Anything else we need here?

@AtsushiSakai
Copy link
Contributor Author

I rebased.

@ViralBShah
Copy link
Member

Whitespace check is failing

@AtsushiSakai
Copy link
Contributor Author

Thank you. The remaining CI failures look unrelated.

@ViralBShah
Copy link
Member

Is this good to merge?

@AtsushiSakai
Copy link
Contributor Author

For me, yes.

@ViralBShah ViralBShah merged commit f6aab71 into JuliaLang:master Feb 12, 2022
@AtsushiSakai AtsushiSakai deleted the patch-3 branch February 12, 2022 14:09
antoine-levitt pushed a commit to antoine-levitt/julia that referenced this pull request Feb 17, 2022
…odes. (JuliaLang#41398)

* Add description to load a local module and using it in example codes.

* make example codes to doctests.

Co-authored-by: Viral B. Shah <[email protected]>
LilithHafner pushed a commit to LilithHafner/julia that referenced this pull request Feb 22, 2022
…odes. (JuliaLang#41398)

* Add description to load a local module and using it in example codes.

* make example codes to doctests.

Co-authored-by: Viral B. Shah <[email protected]>
LilithHafner pushed a commit to LilithHafner/julia that referenced this pull request Mar 8, 2022
…odes. (JuliaLang#41398)

* Add description to load a local module and using it in example codes.

* make example codes to doctests.

Co-authored-by: Viral B. Shah <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:docs This change adds or pertains to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Example in Modules documentation throws an error Examples of using and import in doc are wrong
3 participants