-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
more updates to Markdown files #14191
Conversation
For more info, see also our [paper at the ACM Scala Symposium 2021](resources/safer-exceptions.pdf). | ||
|
||
|
||
For more info, see also our [paper at the ACM Scala Symposium 2021](https://infoscience.epfl.ch/record/290885). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The original link seems to work well. Why the indirection?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@liufengyun Here are two facts to support the change :
-
From the quick scan below of repository
lampepfl/dotty
we can see thatsafer-exceptions.pdf
is the only PDF document (directorycommunity-build/
excepted) :dotty>where /r . *.pdf |wc -l 17 dotty>where /r community-build *.pdf |wc -l 16 dotty>where /r docs *.pdf dotty\docs\resources\safer-exceptions.pdf
Side note: The file is not needed to build Scala binaries or docs (and there exist over 800 forks of
lampepfl/dotty
!). -
Accessing PDF publications from Infoscience is the way to go IMO, e.g.
- LAMP publications (166 records)
- Fengyun's publications (16 records)
For instance, "Dependent Object Types", the seminal paper from Nada, Adriaan and Martin, is available from Infoscience resp. is not included in
lampepfl/dotty
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see now that the PDF poses a problem if we are going to build a PDF version of the spec. That sounds like a strong argument for the change.
Maybe we can remove the PDF from the repo?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see now that the PDF poses a problem if we are going to build a PDF version of the spec. That sounds like a strong argument for the change.
Maybe we can remove the PDF from the repo?
Indeed.
|
||
<details> | ||
<summary>Examples</summary> | ||
<summary>Example 1</summary> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is only one example, what about:
<summary>Example 1</summary> | |
<summary>Show example</summary> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@liufengyun other-new-features/experimental-defs.md
is the Markdown file with the most changes.
Here are two notes about my changes to that file :
-
The text inside the
<details>
-block is handled differently if generating HTML code or generating a PDF document. In particular the show/hide mechanism associated with<details>
-blocks is stripped out when generating a PDF document. -
Initially the
<details>
-blocks did include all code examples for each of 5 elements of the numbered list.<details> <summary>Examples</summary> <pre> // code 1 </pre> <pre> // code 2 </pre> <pre> ... </pre> </details>
In the PR version I choose a more modular approach where each code example is enclosed in a
<details>
-block with a simple introducing text "Examples : " at the end the preceding text paragraph (as encountered in the rest of the Scala 3 Reference). The end result in HTML looks as follows :Example 1
// code example 1
Example 2
// code example 2
...Example 3
// code example 3
Final notes (feedback is welcome !) :
- One possible improvement would be to add a short description for each example, e.g. "Example 1 : bla bla bla" instead of just "Example 1".
- At some point I also considered the option to split some code examples in order to have both examples which compile correctly and examples which generate errors.
Follow up of PR #10767, #10826, #10860, #10875, #10953, #11016, #11062, #11158, #11235 and #11480.
Brings further updates to Markdown files in
docs/reference/
.dropped-features/symlits.md
.other-new-features/experimental-defs.md
.java.lang.Serializable
in sectionother-new-features/transparent-traits.md
.other-new-features/open-classes.md
.experimental/canthrow.md
; local fileresources/safer-exceptions.pdf
is not needed since it is also available from EPFL InfoScience.as
in sectionsoft-modifier.md
.throws
in sectionsyntax.md
.PS. The above changes can be viewed in the PDF document
scala3_reference.pdf
(1 Mb) generated with Pandoc 2.16 (PR#11257).