Skip to content

Scaladoc - clean preprocessing leftovers #14055

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

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,8 @@ jobs:
DOTTY_WEBSITE_BOT_TOKEN: ${{ secrets.BOT_TOKEN }} # If you need to change this:
# Generate one at https://github.com/settings/tokens
# Make sure you have the write permissions to the repo: https://github.com/lampepfl/dotty-website
DOCS_SCALALANG_BOT_TOKEN: ${{ secrets.DOCS_SCALALANG_BOT_TOKEN }} # If you need to change this:
# Currently unused token, no need to deploy anything to docs.scala-lang
# DOCS_SCALALANG_BOT_TOKEN: ${{ secrets.DOCS_SCALALANG_BOT_TOKEN }} # If you need to change this:
# Generate one at https://github.com/settings/tokens
# Make sure you have the write permissions to the repo: https://github.com/scala/docs.scala-lang

Expand Down
9 changes: 3 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,6 @@ cs
# Coursier test product
compiler/test-coursier/run/*.jar

# Docs
docs-for-dotty-page/*

# docs.scala-lang deplyment temp dir
docsScalaLang/
docs/_site/
# docs related
contributors.js
content-contributors.css
1 change: 0 additions & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ val scaladoc = Build.scaladoc
val `scaladoc-testcases` = Build.`scaladoc-testcases`
val `scaladoc-js-common` = Build.`scaladoc-js-common`
val `scaladoc-js-main` = Build.`scaladoc-js-main`
val `scaladoc-js-markdown` = Build.`scaladoc-js-markdown`
val `scaladoc-js-contributors` = Build.`scaladoc-js-contributors`
val `scala3-bench-run` = Build.`scala3-bench-run`
val dist = Build.dist
Expand Down
4 changes: 0 additions & 4 deletions docs/README.md

This file was deleted.

9 changes: 0 additions & 9 deletions docs/docs/reference/changed-features.md

This file was deleted.

7 changes: 7 additions & 0 deletions docs/docs/reference/changed-features/changed-features.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
layout: doc-page
title: "Other Changed Features"
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features.html
---

The following pages document the features that have changed in Scala 3, compared to Scala 2.
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/compiler-plugins.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Changes in Compiler Plugins"
type: section
num: 68
previous-page: /scala3/reference/changed-features/eta-expansion
next-page: /scala3/reference/changed-features/lazy-vals-init
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/compiler-plugins.html
---

Compiler plugins are supported by Dotty (and Scala 3) since 0.9. There are two notable changes
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/reference/changed-features/eta-expansion-spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: singlepage-overview
scala3: true
layout: doc-page
title: "Automatic Eta Expansion - More Details"
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/eta-expansion-spec.html
---

## Motivation
Expand Down
10 changes: 4 additions & 6 deletions docs/docs/reference/changed-features/eta-expansion.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Automatic Eta Expansion"
type: section
num: 67
previous-page: /scala3/reference/changed-features/pattern-matching
next-page: /scala3/reference/changed-features/compiler-plugins
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/eta-expansion.html
---

The conversion of _methods_ into _functions_ has been improved and happens automatically for methods with one or more parameters.
Expand Down Expand Up @@ -38,7 +36,7 @@ rather than `next _`.
The reason for excluding nullary methods from automatic eta expansion
is that Scala implicitly inserts the `()` argument, which would
conflict with eta expansion. Automatic `()` insertion is
[limited](../dropped-features/auto-apply.html) in Scala 3, but the fundamental ambiguity
[limited](../dropped-features/auto-apply.md) in Scala 3, but the fundamental ambiguity
remains.

[More details](eta-expansion-spec.html)
[More details](eta-expansion-spec.md)
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: singlepage-overview
scala3: true
layout: doc-page
title: "Implicit Conversions - More Details"
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/implicit-conversions-spec.html
---

## Implementation
Expand Down Expand Up @@ -82,7 +82,7 @@ implicit val myConverter: Int => String = _.toString
implicit val myConverter: Conversion[Int, String] = _.toString
```

Note that implicit conversions are also affected by the [changes to implicit resolution](implicit-resolution.html) between Scala 2 and Scala 3.
Note that implicit conversions are also affected by the [changes to implicit resolution](implicit-resolution.md) between Scala 2 and Scala 3.

## Motivation for the changes

Expand All @@ -109,9 +109,9 @@ will report a type error, because `Map` isn't an instance of
Implicit values that are used as views should see their type changed to `Conversion`.

For the migration of implicit conversions that are affected by the
changes to implicit resolution, refer to the [Changes in Implicit Resolution](implicit-resolution.html) for more information.
changes to implicit resolution, refer to the [Changes in Implicit Resolution](implicit-resolution.md) for more information.

## Reference

For more information about implicit resolution, see [Changes in Implicit Resolution](implicit-resolution.html).
For more information about implicit resolution, see [Changes in Implicit Resolution](implicit-resolution.md).
Other details are available in [PR #2065](https://github.com/lampepfl/dotty/pull/2065).
8 changes: 3 additions & 5 deletions docs/docs/reference/changed-features/implicit-conversions.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Implicit Conversions"
type: section
num: 61
previous-page: /scala3/reference/changed-features/implicit-resolution
next-page: /scala3/reference/changed-features/overload-resolution
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/implicit-conversions.html
---

An _implicit conversion_, also called _view_, is a conversion that
Expand Down Expand Up @@ -63,4 +61,4 @@ implicitly[Ordering[A]] // Ok, will use the implicit conversion from
// `A` to `Int` and the `Ordering` for `Int`.
```

[More details](implicit-conversions-spec.html)
[More details](implicit-conversions-spec.md)
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/implicit-resolution.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Changes in Implicit Resolution"
type: section
num: 60
previous-page: /scala3/reference/changed-features/type-inference
next-page: /scala3/reference/changed-features/implicit-conversions
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/implicit-resolution.html
---

This section describes changes to the implicit resolution that apply both to the new `given`s and to the old-style `implicit`s in Scala 3.
Expand Down
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/imports.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Imports"
type: section
num: 57
previous-page: /scala3/reference/changed-features/wildcards
next-page: /scala3/reference/changed-features/type-checking
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/imports.html
---

The syntax of wildcard and renaming imports (and exports) has changed.
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/reference/changed-features/interpolation-escapes.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: singlepage-overview
scala3: true
layout: doc-page
title: "Escapes in interpolations"
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/interpolation-escapes.html
---

In Scala 2 there is no straightforward way to represent a single quote character `"` in a single quoted interpolation. A `\` character can't be used for that because interpolators themselves decide how to handle escaping, so the parser doesn't know whether the `"` should be escaped or used as a terminator.
Expand Down
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/lazy-vals-init.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: Lazy Vals Initialization
type: section
num: 69
previous-page: /scala3/reference/changed-features/compiler-plugins
next-page: /scala3/reference/changed-features/main-functions
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/lazy-vals-init.html
---

Scala 3 implements [Version 6](https://docs.scala-lang.org/sips/improved-lazy-val-initialization.html#version-6---no-synchronization-on-this-and-concurrent-initialization-of-fields)
Expand Down
8 changes: 3 additions & 5 deletions docs/docs/reference/changed-features/main-functions.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Main Methods"
type: section
num: 70
previous-page: /scala3/reference/changed-features/lazy-vals-init
next-page: /scala3/reference/dropped-features
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/main-functions.html
---

Scala 3 offers a new way to define programs that can be invoked from the command line:
Expand Down Expand Up @@ -87,5 +85,5 @@ object happyBirthday extends App:
...
```

The previous functionality of `App`, which relied on the "magic" [`DelayedInit`]({% link _scala3-reference/dropped-features/delayed-init.md %}) trait, is no longer available. [`App`](https://scala-lang.org/api/3.x/scala/App.html) still exists in limited form for now, but it does not support command line arguments and will be deprecated in the future. If programs need to cross-build
The previous functionality of `App`, which relied on the "magic" [`DelayedInit`](../dropped-features/delayed-init.md) trait, is no longer available. [`App`](https://scala-lang.org/api/3.x/scala/App.md) still exists in limited form for now, but it does not support command line arguments and will be deprecated in the future. If programs need to cross-build
between Scala 2 and Scala 3, it is recommended to use an explicit `main` method with an `Array[String]` argument instead.
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/match-syntax.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Match Expressions"
type: section
num: 63
previous-page: /scala3/reference/changed-features/overload-resolution
next-page: /scala3/reference/changed-features/vararg-splices
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/match-syntax.html
---

The syntactical precedence of match expressions has been changed.
Expand Down
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/numeric-literals.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Numeric Literals"
type: section
num: 53
previous-page: /scala3/reference/changed-features
next-page: /scala3/reference/changed-features/structural-types
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/numeric-literals.html
---

[Document was moved](../experimental/numeric-literals.md)
10 changes: 4 additions & 6 deletions docs/docs/reference/changed-features/operators.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
---
layout: doc-page
title: "Rules for Operators"
type: section
num: 55
previous-page: /scala3/reference/changed-features/structural-types
next-page: /scala3/reference/changed-features/wildcards
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/operators.html
---

The rules for infix operators have changed in some parts:

First, an alphanumeric method can be used as an infix operator only if its definition carries an `infix` modifier. Second, it is recommended (but not enforced) to
augment definitions of symbolic operators with [`@targetName` annotations](../other-new-features/targetName.html). Finally,
augment definitions of symbolic operators with [`@targetName` annotations](../other-new-features/targetName.md). Finally,
a syntax change allows infix operators to be written on the left in a multi-line expression.

## The `infix` Modifier
Expand Down Expand Up @@ -99,7 +97,7 @@ or if the `-source future` option is given in Dotty/Scala 3.

## The `@targetName` Annotation

It is recommended that definitions of symbolic operators carry a [`@targetName` annotation](../other-new-features/targetName.html) that provides an encoding of the operator with an alphanumeric name. This has several benefits:
It is recommended that definitions of symbolic operators carry a [`@targetName` annotation](../other-new-features/targetName.md) that provides an encoding of the operator with an alphanumeric name. This has several benefits:

- It helps interoperability between Scala and other languages. One can call
a Scala-defined symbolic operator from another language using its target name,
Expand Down
8 changes: 3 additions & 5 deletions docs/docs/reference/changed-features/overload-resolution.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Changes in Overload Resolution"
type: section
num: 62
previous-page: /scala3/reference/changed-features/implicit-conversions
next-page: /scala3/reference/changed-features/match-syntax
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/overload-resolution.html
---

Overload resolution in Scala 3 improves on Scala 2 in two ways.
Expand Down Expand Up @@ -44,7 +42,7 @@ resolution yields several competing alternatives when `n >= 1` parameter lists a
into account, then resolution re-tried using `n + 1` argument lists.

This change is motivated by the new language feature
[extension methods](../contextual/extension-methods.html), where emerges the need to do
[extension methods](../contextual/extension-methods.md), where emerges the need to do
overload resolution based on additional argument blocks.

## Parameter Types of Function Values
Expand Down
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/pattern-bindings.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Pattern Bindings"
type: section
num: 65
previous-page: /scala3/reference/changed-features/vararg-splices
next-page: /scala3/reference/changed-features/pattern-matching
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/pattern-bindings.html
---

In Scala 2, pattern bindings in `val` definitions and `for` expressions are
Expand Down
8 changes: 3 additions & 5 deletions docs/docs/reference/changed-features/pattern-matching.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Option-less pattern matching"
type: section
num: 66
previous-page: /scala3/reference/changed-features/pattern-bindings
next-page: /scala3/reference/changed-features/eta-expansion
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/pattern-matching.html
---

The implementation of pattern matching in Scala 3 was greatly simplified compared to Scala 2. From a user perspective, this means that Scala 3 generated patterns are a *lot* easier to debug, as variables all show up in debug modes and positions are correctly preserved.
Expand Down Expand Up @@ -243,4 +241,4 @@ Abstract type testing with `ClassTag` is replaced with `TypeTest` or the alias `
- pattern `_: X` for an abstract type requires a `TypeTest` in scope
- pattern `x @ X()` for an unapply that takes an abstract type requires a `TypeTest` in scope

[More details on `TypeTest`](../other-new-features/type-test.html)
[More details on `TypeTest`](../other-new-features/type-test.md)
6 changes: 3 additions & 3 deletions docs/docs/reference/changed-features/structural-types-spec.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
layout: singlepage-overview
scala3: true
layout: doc-page
title: "Programmatic Structural Types - More Details"
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/structural-types-spec.html
---

## Syntax
Expand Down Expand Up @@ -81,7 +81,7 @@ and `Rs` are structural refinement declarations, and given `v.a` of type `U`, we

Note that `v`'s static type does not necessarily have to conform to `Selectable`, nor does it need to have `selectDynamic` and `applyDynamic` as members. It suffices that there is an implicit
conversion that can turn `v` into a `Selectable`, and the selection methods could also be available as
[extension methods](../contextual/extension-methods.html).
[extension methods](../contextual/extension-methods.md).

## Limitations of Structural Types

Expand Down
8 changes: 3 additions & 5 deletions docs/docs/reference/changed-features/structural-types.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Programmatic Structural Types"
type: section
num: 54
previous-page: /scala3/reference/changed-features/numeric-literals
next-page: /scala3/reference/changed-features/operators
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/structural-types.html
---

## Motivation
Expand Down Expand Up @@ -191,4 +189,4 @@ differences.
`java.lang.Class` arguments indicating the method's formal parameter types.
`Dynamic` comes with `updateDynamic`.

[More details](structural-types-spec.html)
[More details](structural-types-spec.md)
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/type-checking.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Changes in Type Checking"
type: section
num: 58
previous-page: /scala3/reference/changed-features/imports
next-page: /scala3/reference/changed-features/type-inference
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/type-checking.html
---

*** **TO BE FILLED IN** ***
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/type-inference.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Changes in Type Inference"
type: section
num: 59
previous-page: /scala3/reference/changed-features/type-checking
next-page: /scala3/reference/changed-features/implicit-resolution
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/type-inference.html
---

For more information, see the two presentations
Expand Down
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/vararg-splices.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: "Vararg Splices"
type: section
num: 64
previous-page: /scala3/reference/changed-features/match-syntax
next-page: /scala3/reference/changed-features/pattern-bindings
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/vararg-splices.html
---

The syntax of vararg splices in patterns and function arguments has changed. The new syntax uses a postfix `*`, analogously to how a vararg parameter is declared.
Expand Down
6 changes: 2 additions & 4 deletions docs/docs/reference/changed-features/wildcards.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
---
layout: doc-page
title: Wildcard Arguments in Types
type: section
num: 56
previous-page: /scala3/reference/changed-features/operators
next-page: /scala3/reference/changed-features/imports
movedTo: https://docs.scala-lang.org/scala3/reference/changed-features/wildcards.html
---

The syntax of wildcard arguments in types has changed from `_` to `?`. Example:
Expand Down
Loading