Skip to content

Fix a number of doc issues #1676

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 4 commits into from
Nov 7, 2016
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
94 changes: 13 additions & 81 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,86 +1,18 @@
dotty
Dotty
=====

[![Join the chat at https://gitter.im/lampepfl/dotty](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/lampepfl/dotty?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)

Dotty is a platform to try out new language concepts and compiler
technologies for Scala. The focus is mainly on simplification. We
remove extraneous syntax (e.g. no XML literals), and try to boil down
Scala's types into a smaller set of more fundamental constructors. The
theory behind these constructors is researched in
[DOT](http://www.cs.uwm.edu/~boyland/fool2012/papers/fool2012_submission_3.pdf),
a calculus for dependent object types.

####Current status:
_Technology preview_: currently unsupported, may be functionally incomplete or unsuitable for production use.

####Is it going to be the future Scala?
Yes, eventually.

####Who's working on it?
See [github contributors page](https://github.com/lampepfl/dotty/graphs/contributors).

####What are the features that could make me consider trying it?
| Feature | Status |
|---------------------------------------------------------------------------------------------------------|---------------------|
| Union, Intersection and [Literal singleton types](http://docs.scala-lang.org/sips/pending/42.type.html) | Implemented |
| Fast compilation(phase fusion) | Implemented |
| [Trait parameters](http://docs.scala-lang.org/sips/pending/trait-parameters.html) | Implemented |
| [@Static methods and fields](https://github.com/scala/scala.github.com/pull/491) | Implemented |
| Colored Repl | Implemented |
| Sbt incremental build | Implemented |
| Non-blocking lazy vals | Implemented |
| Multiverse equality | Implemented |
| Option-less pattern matching(based on [name-based patmat](https://github.com/scala/scala/pull/2848)) | Implemented |
| Function arity adaptation | Implemented |
| Exhaustivity checks in pattern matching | Implemented |
| | |
| Non-boxed arrays of value classes | In progress |
| Working contravariant implicits | In progress |
| [Auto-Specialization](https://github.com/dotty-linker/dotty) | In progress |
| [Whole program optimizer](https://github.com/dotty-linker/dotty) | In progress |
| [Library defined optimizations](https://github.com/dotty-linker/dotty) | In progress |
| | |
| HList & HMaps\Record types | Under consideration |
| Implicit functions | Under consideration |
| Effects | Under consideration |
| Auto-completion in repl | Under consideration |
| Spec Option-less pattern matching | Under consideration |

There are also plethora of small details such as [per-callsite @tailrec annotations](https://github.com/lampepfl/dotty/issues/1221)

####What are the complications that I can have If I start using Dotty?
Dotty can use libraries compiled by scalac 2.11, but Scala scalac can't use libraries compiled by Dotty.<br>
No existential types.<br>
No macro support yet. We have big plans here.<br>
No early initializers. No scala.DelayedInit. Use trait parameters instead.<br>
Whole program optimizer will only work if all dependencies are compiled by Dotty.<br>


####Can I write my code in a way that is going to be compatible with Scalac & Dotty?
Yes, Dotty itself is a project that can be compiled by both Dotty and Scalac.<br>
It's not very hard, and the biggest thing that you will likely miss is using macros.

####How can I try it out?
http://lampepfl.github.io/dotty/docs/contributing/getting-started.html.
Here’s an example sbt project and instructions on how to set it up: https://github.com/smarter/dotty-example-project/ <br>
We have colored REPL :-). You can invoke it by running `dotc -repl`.

####We also have:
Basic support for Scala.js,<br>
[Prototype](https://github.com/scala-native/scala-native/tree/topic/dotty-support) of compilation to x86 native code(Shabalin)<br>

####What about scalac:
Scalac is the basis for stability in scala. We expect scalac & dotty to coexist for long time.

####Contributions are welcome!
We invite you to help us build the future of Scala.<br>
This is the best moment to participate, as everyone can make an impact.<br>

####SI-2712?
Since scalac merged a fix into 2.12, we’ll mimic their behaviour. But we have bigger plans for
HK-types.

* [Homepage](http://dotty.epfl.ch)
* [Documentation](http://dotty.epfl.ch/docs)
* [FAQ](http://dotty.epfl.ch/#why-dotty)
* [Mailing list](https://groups.google.com/forum/#!forum/dotty-internals)

How to Contribute
=================
* [Getting Started](http://dotty.epfl.ch/docs/contributing/getting-started.html)
* [Awesome Error Messages](http://scala-lang.org/blog/2016/10/14/dotty-errors.html)
* [Issues](https://github.com/lampepfl/dotty/issues?q=is%3Aissue+is%3Aopen+label%3A%22help+wanted%22)

Developers mailing list is https://groups.google.com/forum/#!forum/dotty-internals.
License
=======
Dotty is licensed under the [3-Clause BSD License](https://github.com/lampepfl/dotty/blob/master/LICENSE.md)
1 change: 1 addition & 0 deletions docs/_config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
title: Dotty Documentation
repository_url: "http://github.com/lampepfl/dotty"
baseurl: ""
theme: minima
gems:
Expand Down
3 changes: 3 additions & 0 deletions docs/_includes/toc.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
{% include scala-logo.html %}
</div>
</a>
<form id="search-form" action="/search.html" method="get">
<input placeholder="Search" type="text" id="search-box" name="query">
</form>
<ul id="categories">
<li><ul><li><a href="{{ site.baseurl }}/blog">Blog</a></li></ul></li>
<li><ul><li><a href="{{ site.baseurl }}/docs">Dotty Docs</a></li></ul></li>
Expand Down
3 changes: 1 addition & 2 deletions docs/_layouts/blog.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@
layout: default
---

<h1 class="title">{{ page.title }}</h1>
<h2 class="subtitle">{{ page.subTitle }}</h2>

<div class="author-container {% if page.authorImg != null %} spaced {% endif %}">
{% if page.authorImg != null %}
<img src="{{ site.baseurl }}/{{ page.authorImg }}"/>
<img src="{{ site.baseurl }}{{ page.authorImg }}"/>
{% endif %}
<div class="author-info">
<div>{{ page.author }}</div>
Expand Down
26 changes: 26 additions & 0 deletions docs/_layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,18 @@
</div>
</a>
<div id="content">
<h1>{{ page.title }}</h1>
<div class="edit-docs">
<a href="{{site.repository_url}}/edit/master/docs/{{page.path}}">[edit on github]</a>
</div>
{{ content }}
</div>
<div id="toc">
{% include toc.html %}
</div>
</div>
</body>
<script src="https://cdnjs.cloudflare.com/ajax/libs/mark.js/8.4.0/mark.min.js"></script>
<script src="{{ site.baseurl }}/js/highlight.pack.js"></script>
<script language="javascript">
hljs.initHighlightingOnLoad();
Expand All @@ -31,5 +36,26 @@
if (thisHREF.indexOf(window.location.hostname) > -1) thisHREF = thisHREF.replace(".md",".html")
document.links[i].setAttribute('href', thisHREF);
}

function getQueryVariable(variable) {
var query = window.location.search.substring(1);
var vars = query.split('&');

for (var i = 0; i < vars.length; i++) {
var pair = vars[i].split('=');

if (pair[0] === variable) {
return decodeURIComponent(pair[1].replace(/\+/g, '%20'));
}
}
}


var highlight = getQueryVariable("highlight");
if (highlight) {
var context = document.querySelector("#content");
var instance = new Mark(context);
instance.mark(highlight);
}
</script>
</html>
17 changes: 17 additions & 0 deletions docs/_layouts/search.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<html>
<head>
<meta charset="utf-8">

<title>Dotty - {{ page.title }}</title>
<link rel="shortcut icon" type="image/png" href="{{ site.baseurl}}/images/favicon.png"/>
<link rel="stylesheet" href="http://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.7.0/styles/github.min.css">
<link rel="stylesheet" href="{{ site.baseurl }}/css/main.css">
</head>
<body>
<div id="container">
<div class="search">
{{ content }}
</div>
</div>
</body>
</html>
2 changes: 0 additions & 2 deletions docs/blog/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
title: "Blog"
---

<h1>Blog</h1>

<ul class="post-list">
{% for post in site.posts %}
<li>
Expand Down
63 changes: 58 additions & 5 deletions docs/css/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ $base-line-height: 1.5;

$spacing-unit: 30px;

$text-color: #111;
$background-color: #fdfdfd;
$text-color: #efefef;
$background-color: #002B36;
$brand-color: #2a7ae2;


Expand All @@ -25,6 +25,8 @@ $blue-light: rgba(52, 152, 219, 0.12);
$grey: #f8f8f8;
$red: #de332e;

$link-color: $blue;

// content area
$distance-top: 80px;
$content-width: 1150px;
Expand All @@ -49,6 +51,14 @@ html {
box-sizing: inherit;
}

*:focus {
outline: none;
}

a, a:focus, a:hover, a:visited {
color: $link-color;
}

div#container {
position: relative;
max-width: $content-width;
Expand All @@ -60,6 +70,7 @@ div#container {
}

div#content {
position: relative;
margin-top: $distance-top;
width: $content-width - $toc-width;
float: right;
Expand All @@ -80,10 +91,25 @@ div#container {
padding-right: 20px;
width: $toc-width;

form#search-form {
input#search-box {
width: 100%;
border: 0;
height: 24px;
font-size: 14px;
padding-left: 4px;
}

input#search-button {
margin-top: 3px;
}
}

> div {
position: fixed;
top: $distance-top;
bottom: auto;
max-width: $toc-width;

a > div#scala-logo {
width: 64px;
Expand Down Expand Up @@ -125,6 +151,27 @@ div#container {
}
}

div.edit-docs {
position: absolute;
top: 8px;
right: 0;
}

h1#search {
margin-top: 50px;
}

form#search-bar {
width: 100%;
> input {
width: 100%;
border: 0;
height: 24px;
font-size: 14px;
padding-left: 4px;
}
}

div.author-container {
height: 50px;
margin-bottom: 15px;
Expand All @@ -135,7 +182,7 @@ div.author-container {
}

> div.author-info {
color: rgba(0,0,0,0.45);
color: rgba(255,255,255,0.45);
float: left;
}
}
Expand All @@ -155,7 +202,7 @@ ul.post-list {

> li {
div.date {
color: rgba(0,0,0,0.45);
color: rgba(255,255,255,0.55);
}
}
}
Expand All @@ -165,12 +212,18 @@ pre, code {
border: 0;
border-radius: 3px;
background-color: $grey;
color: $background-color;
font-family: $code-font-family;
}

code {
padding-left: 0.1em;
padding-right: 0.1em;
}

body {
font: 400 16px/1.5 "Helvetica Neue", Helvetica, Arial, sans-serif;
color: #111;
color: $text-color;
}

@include media-query(1166px) {
Expand Down
5 changes: 1 addition & 4 deletions docs/docs/contributing/eclipse.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
---
layout: default
title: Eclipse
title: "Building Dotty with Eclipse"
---

Building Dotty with Eclipse
===========================

Build setup
-----------
You may need to redo these steps when the build changes.
Expand Down
3 changes: 0 additions & 3 deletions docs/docs/contributing/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ layout: default
title: "Getting Started"
---

Getting Started
===============

Talks on Dotty
--------------
- [Scala's Road Ahead](https://www.youtube.com/watch?v=GHzWqJKFCk4) by Martin Odersky [\[slides\]](http://www.slideshare.net/Odersky/scala-days-nyc-2016)
Expand Down
3 changes: 1 addition & 2 deletions docs/docs/contributing/intellij-idea.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
layout: default
title: "Building Dotty with Intellij IDEA"
---

Building Dotty with Intellij IDEA
=================================
Dotty compiler support is available in the [Scala plugin nightly] starting
from 2.2.39. You need to install [IDEA 2016.1] to try it.

Expand Down
2 changes: 0 additions & 2 deletions docs/docs/contributing/workflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ layout: default
title: "Workflow"
---

Workflow
========
This document details common workflow patterns when working with Dotty.

## Compiling files with dotc ##
Expand Down
4 changes: 1 addition & 3 deletions docs/docs/index.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
---
layout: default
title: "Docs"
title: "Dotty Documentation"
---

Dotty Documentation
===================
The Dotty compiler is currently somewhat lacking in documentation - PRs
welcome! But, we've attempted to gather the most essential knowledge in these
pages.
Expand Down
Loading