mirror of
https://github.com/roc-lang/roc.git
synced 2025-07-07 14:44:59 +00:00
s/rtfeldman/roc-lang/g in links to GitHub repos
This commit is contained in:
parent
af8a81de9f
commit
97e2900bf5
84 changed files with 174 additions and 174 deletions
2
.github/workflows/nightly_linux_x86_64.yml
vendored
2
.github/workflows/nightly_linux_x86_64.yml
vendored
|
@ -22,7 +22,7 @@ jobs:
|
|||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # automatically provided by github actions
|
||||
with:
|
||||
upload_url: https://uploads.github.com/repos/rtfeldman/roc/releases/51880579/assets{?name,label}
|
||||
upload_url: https://uploads.github.com/repos/roc-lang/roc/releases/51880579/assets{?name,label}
|
||||
release_id: 51880579
|
||||
asset_path: ./roc_linux_x86_64.tar.gz
|
||||
asset_name: roc_nightly-linux_x86_64-$$.tar.gz # $$ inserts 6 char commit hash and date (YYYY-MM-DD)
|
||||
|
|
|
@ -15,7 +15,7 @@ jobs:
|
|||
run: zig version
|
||||
- name: llvm version
|
||||
run: llc --version | grep LLVM
|
||||
- name: run tests
|
||||
- name: run tests
|
||||
run: cargo test --locked --release
|
||||
- name: write version to file
|
||||
run: ./ci/write_version.sh
|
||||
|
@ -28,7 +28,7 @@ jobs:
|
|||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # automatically provided by github actions
|
||||
with:
|
||||
upload_url: https://uploads.github.com/repos/rtfeldman/roc/releases/51880579/assets{?name,label}
|
||||
upload_url: https://uploads.github.com/repos/roc-lang/roc/releases/51880579/assets{?name,label}
|
||||
release_id: 51880579
|
||||
asset_path: ./roc_darwin_apple_silicon.tar.gz
|
||||
asset_name: roc_nightly-macos_apple_silicon-$$.tar.gz # $$ inserts 6 char commit hash and date (YYYY-MM-DD)
|
||||
|
|
2
.github/workflows/nightly_macos_x86_64.yml
vendored
2
.github/workflows/nightly_macos_x86_64.yml
vendored
|
@ -44,7 +44,7 @@ jobs:
|
|||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # automatically provided by github actions
|
||||
with:
|
||||
upload_url: https://uploads.github.com/repos/rtfeldman/roc/releases/51880579/assets{?name,label}
|
||||
upload_url: https://uploads.github.com/repos/roc-lang/roc/releases/51880579/assets{?name,label}
|
||||
release_id: 51880579
|
||||
asset_path: ./roc_darwin_x86_64.tar.gz
|
||||
asset_name: roc_nightly-macos_x86_64-$$.tar.gz # $$ inserts 6 char commit hash and date (YYYY-MM-DD)
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||
Upstream-Name: Roc
|
||||
Upstream-Contact: Richard Feldman <oss@rtfeldman.com>
|
||||
Source: https://github.com/rtfeldman/roc
|
||||
Source: https://github.com/roc-lang/roc
|
||||
|
||||
Files: *
|
||||
Copyright: © The Roc Contributors
|
||||
|
|
|
@ -28,7 +28,7 @@ Earthly may temporarily use a lot of disk space, up to 90 GB. This disk space is
|
|||
## Contribution Tips
|
||||
|
||||
- Create an issue if the purpose of a struct/field/type/function/... is not immediately clear from its name or nearby comments.
|
||||
- You find good first issues [here](https://github.com/rtfeldman/roc/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22).
|
||||
- You find good first issues [here](https://github.com/roc-lang/roc/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22).
|
||||
- Before making your first pull request, definitely talk to an existing contributor on [Roc Zulip](https://roc.zulipchat.com) first about what you plan to do! This can not only avoid duplicated effort, it can also avoid making a whole PR only to discover it won't be accepted because the change doesn't fit with the goals of the language's design or implementation.
|
||||
- It's a good idea to open a work-in-progress pull request as you begin working on something. This way, others can see that you're working on it, which avoids duplicate effort, and others can give feedback sooner rather than later if they notice a problem in the direction things are going. Be sure to include "WIP" in the title of the PR as long as it's not ready for review!
|
||||
- Make sure to create a branch on the roc repository for your changes. We do not allow CI to be run on forks for security.
|
||||
|
|
10
Cargo.lock
generated
10
Cargo.lock
generated
|
@ -1819,13 +1819,13 @@ checksum = "05a0bd019339e5d968b37855180087b7b9d512c5046fbd244cf8c95687927d6e"
|
|||
name = "inkwell"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"inkwell 0.1.0 (git+https://github.com/rtfeldman/inkwell?branch=master)",
|
||||
"inkwell 0.1.0 (git+https://github.com/roc-lang/inkwell?branch=master)",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "inkwell"
|
||||
version = "0.1.0"
|
||||
source = "git+https://github.com/rtfeldman/inkwell?branch=master#accd406858a40ca2a1463ff77d79f3c5e4c96f4e"
|
||||
source = "git+https://github.com/roc-lang/inkwell?branch=master#accd406858a40ca2a1463ff77d79f3c5e4c96f4e"
|
||||
dependencies = [
|
||||
"either",
|
||||
"inkwell_internals",
|
||||
|
@ -1838,7 +1838,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "inkwell_internals"
|
||||
version = "0.5.0"
|
||||
source = "git+https://github.com/rtfeldman/inkwell?branch=master#accd406858a40ca2a1463ff77d79f3c5e4c96f4e"
|
||||
source = "git+https://github.com/roc-lang/inkwell?branch=master#accd406858a40ca2a1463ff77d79f3c5e4c96f4e"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
|
@ -4208,7 +4208,7 @@ checksum = "a0a5f7c728f5d284929a1cccb5bc19884422bfe6ef4d6c409da2c41838983fcf"
|
|||
[[package]]
|
||||
name = "rustyline"
|
||||
version = "9.1.1"
|
||||
source = "git+https://github.com/rtfeldman/rustyline?rev=e74333c#e74333c0d618896b88175bf06645108f996fe6d0"
|
||||
source = "git+https://github.com/roc-lang/rustyline?rev=e74333c#e74333c0d618896b88175bf06645108f996fe6d0"
|
||||
dependencies = [
|
||||
"bitflags",
|
||||
"cfg-if 1.0.0",
|
||||
|
@ -4231,7 +4231,7 @@ dependencies = [
|
|||
[[package]]
|
||||
name = "rustyline-derive"
|
||||
version = "0.6.0"
|
||||
source = "git+https://github.com/rtfeldman/rustyline?rev=e74333c#e74333c0d618896b88175bf06645108f996fe6d0"
|
||||
source = "git+https://github.com/roc-lang/rustyline?rev=e74333c#e74333c0d618896b88175bf06645108f996fe6d0"
|
||||
dependencies = [
|
||||
"quote",
|
||||
"syn",
|
||||
|
|
2
FAQ.md
2
FAQ.md
|
@ -458,7 +458,7 @@ The short explanation for why Roc is released under the [Universal Permissive Li
|
|||
- It's one license, unlike "MIT or Apache2, at your choice" (which is how [Rust addressed the problem](https://internals.rust-lang.org/t/rationale-of-apache-dual-licensing/8952/4) of MIT not having patent protections but Apache2 not being GPLv2 compatible)
|
||||
- It's been approved by OSI, FSF, and Oracle's lawyers, so it has been not only vetted by three giants in the world of software licensing, but also three giants with competing interests - and they all approved it.
|
||||
|
||||
There's also [a longer explanation](https://github.com/rtfeldman/roc/issues/1199) with more detail about the motivation and thought process, if you're interested.
|
||||
There's also [a longer explanation](https://github.com/roc-lang/roc/issues/1199) with more detail about the motivation and thought process, if you're interested.
|
||||
|
||||
## Why does Roc use both Rust and Zig?
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
Roc is not ready for an 0.1 release yet, but we have a [Zulip chat](https://roc.zulipchat.com) where you can learn more about the project.
|
||||
|
||||
If you'd like to get involved in contributing to the language, the Zulip chat is also the best place to get help with [good first issues](https://github.com/rtfeldman/roc/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22).
|
||||
If you'd like to get involved in contributing to the language, the Zulip chat is also the best place to get help with [good first issues](https://github.com/roc-lang/roc/issues?q=is%3Aopen+is%3Aissue+label%3A%22good+first+issue%22).
|
||||
|
||||
# Sponsors
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ Enjoy!
|
|||
|
||||
## Getting started
|
||||
|
||||
Learn how to install roc on your machine [here](https://github.com/rtfeldman/roc#getting-started).
|
||||
Learn how to install roc on your machine [here](https://github.com/roc-lang/roc#getting-started).
|
||||
|
||||
## Strings and Numbers
|
||||
|
||||
|
|
|
@ -2614,7 +2614,7 @@ pub mod test_constrain {
|
|||
#[test]
|
||||
fn inference_var_tag_union_ext() {
|
||||
// TODO: we should really be inferring [Blue, Orange]a -> [Lavender, Peach]a here.
|
||||
// See https://github.com/rtfeldman/roc/issues/2053
|
||||
// See https://github.com/roc-lang/roc/issues/2053
|
||||
infer_eq(
|
||||
indoc!(
|
||||
r#"
|
||||
|
|
|
@ -943,7 +943,7 @@ pub fn canonicalize_defs<'a>(
|
|||
)
|
||||
}
|
||||
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#[derive(Debug)]
|
||||
#[allow(clippy::large_enum_variant)]
|
||||
pub enum Declaration {
|
||||
|
|
|
@ -3,7 +3,7 @@ name = "roc_cli"
|
|||
version = "0.1.0"
|
||||
authors = ["The Roc Contributors"]
|
||||
license = "UPL-1.0"
|
||||
repository = "https://github.com/rtfeldman/roc"
|
||||
repository = "https://github.com/roc-lang/roc"
|
||||
edition = "2021"
|
||||
description = "A CLI for Roc"
|
||||
default-run = "roc"
|
||||
|
|
|
@ -3,7 +3,7 @@ name = "cli_utils"
|
|||
version = "0.1.0"
|
||||
authors = ["The Roc Contributors"]
|
||||
license = "UPL-1.0"
|
||||
repository = "https://github.com/rtfeldman/roc"
|
||||
repository = "https://github.com/roc-lang/roc"
|
||||
edition = "2021"
|
||||
description = "Shared code for cli tests and benchmarks"
|
||||
|
||||
|
|
|
@ -214,7 +214,7 @@ pub fn run_with_valgrind<'a, I: IntoIterator<Item = &'a str>>(
|
|||
cmd.arg("--xml=yes");
|
||||
|
||||
// If you are having valgrind issues on MacOS, you may need to suppress some
|
||||
// of the errors. Read more here: https://github.com/rtfeldman/roc/issues/746
|
||||
// of the errors. Read more here: https://github.com/roc-lang/roc/issues/746
|
||||
if let Some(suppressions_file_os_str) = env::var_os("VALGRIND_SUPPRESSIONS") {
|
||||
match suppressions_file_os_str.to_str() {
|
||||
None => {
|
||||
|
|
|
@ -172,7 +172,7 @@ ask the compiler to emit debug information during various stages of compilation.
|
|||
|
||||
There are some goals for more sophisticated debugging tools:
|
||||
|
||||
- A nicer unification debugger, see https://github.com/rtfeldman/roc/issues/2486.
|
||||
- A nicer unification debugger, see https://github.com/roc-lang/roc/issues/2486.
|
||||
Any interest in helping out here is greatly appreciated.
|
||||
|
||||
### General Tips
|
||||
|
|
|
@ -3,6 +3,6 @@ name = "arena-pool"
|
|||
version = "0.0.1"
|
||||
authors = ["The Roc Contributors"]
|
||||
license = "UPL-1.0"
|
||||
repository = "https://github.com/rtfeldman/roc"
|
||||
repository = "https://github.com/roc-lang/roc"
|
||||
edition = "2021"
|
||||
description = "A CLI for Roc"
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod link;
|
||||
pub mod program;
|
||||
|
|
|
@ -961,7 +961,7 @@ fn link_linux(
|
|||
// ld.lld requires this argument, and does not accept --arch
|
||||
// .args(&["-L/usr/lib/x86_64-linux-gnu"])
|
||||
.args(&[
|
||||
// Libraries - see https://github.com/rtfeldman/roc/pull/554#discussion_r496365925
|
||||
// Libraries - see https://github.com/roc-lang/roc/pull/554#discussion_r496365925
|
||||
// for discussion and further references
|
||||
"-lc",
|
||||
"-lm",
|
||||
|
@ -1044,7 +1044,7 @@ fn link_macos(
|
|||
}
|
||||
|
||||
ld_command.args(&[
|
||||
// Libraries - see https://github.com/rtfeldman/roc/pull/554#discussion_r496392274
|
||||
// Libraries - see https://github.com/roc-lang/roc/pull/554#discussion_r496392274
|
||||
// for discussion and further references
|
||||
"-lSystem",
|
||||
"-lresolv",
|
||||
|
@ -1069,7 +1069,7 @@ fn link_macos(
|
|||
"QuartzCore",
|
||||
// "-lrt", // TODO shouldn't we need this?
|
||||
// "-lc_nonshared", // TODO shouldn't we need this?
|
||||
// "-lgcc", // TODO will eventually need compiler_rt from gcc or something - see https://github.com/rtfeldman/roc/pull/554#discussion_r496370840
|
||||
// "-lgcc", // TODO will eventually need compiler_rt from gcc or something - see https://github.com/roc-lang/roc/pull/554#discussion_r496370840
|
||||
"-framework",
|
||||
"Security",
|
||||
// Output
|
||||
|
|
|
@ -182,7 +182,7 @@ comptime {
|
|||
|
||||
// Utils continued - SJLJ
|
||||
// For tests (in particular test_gen), roc_panic is implemented in terms of
|
||||
// setjmp/longjmp. LLVM is unable to generate code for longjmp on AArch64 (https://github.com/rtfeldman/roc/issues/2965),
|
||||
// setjmp/longjmp. LLVM is unable to generate code for longjmp on AArch64 (https://github.com/roc-lang/roc/issues/2965),
|
||||
// so instead we ask Zig to please provide implementations for us, which is does
|
||||
// (seemingly via musl).
|
||||
pub extern fn setjmp([*c]c_int) c_int;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod bitcode;
|
||||
pub mod roc;
|
||||
|
|
|
@ -232,7 +232,7 @@ impl PendingTypeDef<'_> {
|
|||
}
|
||||
}
|
||||
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#[derive(Clone, Debug)]
|
||||
#[allow(clippy::large_enum_variant)]
|
||||
pub enum Declaration {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod abilities;
|
||||
pub mod annotation;
|
||||
|
|
|
@ -1023,7 +1023,7 @@ mod test_can {
|
|||
# There was a bug where annotating a def meant that its
|
||||
# references no longer got reported.
|
||||
#
|
||||
# https://github.com/rtfeldman/roc/issues/298
|
||||
# https://github.com/roc-lang/roc/issues/298
|
||||
x : List Booly
|
||||
x = [y]
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
pub mod all;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod builtins;
|
||||
pub mod expr;
|
||||
|
|
|
@ -130,7 +130,7 @@ impl Env<'_> {
|
|||
// we only expect `bar` to polymorphic at this stage!
|
||||
//
|
||||
// TODO: it would be better if `unify` could prune these for us. See also
|
||||
// https://github.com/rtfeldman/roc/issues/3207; that is a blocker for this TODO.
|
||||
// https://github.com/roc-lang/roc/issues/3207; that is a blocker for this TODO.
|
||||
#[cfg(debug_assertions)]
|
||||
{
|
||||
for (spec_var, lambda_sets) in _lambda_sets_to_specialize.drain() {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod annotation;
|
||||
pub mod collection;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Dev Backend
|
||||
|
||||
The dev backend is focused on generating decent binaries extremely fast.
|
||||
It goes from Roc's [mono ir](https://github.com/rtfeldman/roc/blob/trunk/compiler/mono/src/ir.rs) to an object file ready to be linked.
|
||||
It goes from Roc's [mono ir](https://github.com/roc-lang/roc/blob/trunk/compiler/mono/src/ir.rs) to an object file ready to be linked.
|
||||
|
||||
## General Process
|
||||
|
||||
|
@ -22,14 +22,14 @@ rust should be abled compile each specific target (`linux-arm`, `darwin-x86_64`,
|
|||
|
||||
### Backend
|
||||
|
||||
[Backend](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/lib.rs) is the core abstraction.
|
||||
[Backend](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/lib.rs) is the core abstraction.
|
||||
It understands Roc's mono ir and some high level ideas about the generation process.
|
||||
The main job of Backend is to do high level optimizatons (like lazy literal loading) and parse the mono ir.
|
||||
Every target specific backend must implement this trait.
|
||||
|
||||
### Backend64Bit
|
||||
|
||||
[Backend64Bit](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs) is more or less what it sounds like.
|
||||
[Backend64Bit](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs) is more or less what it sounds like.
|
||||
It is the backend that understands 64 bit architectures.
|
||||
Currently it is the only backend implementation, but a 32 bit implementation will probably come in the future.
|
||||
This backend understands that the unit of data movement is 64 bit.
|
||||
|
@ -44,39 +44,39 @@ Backend64Bit is generic over these types instead of containing these types withi
|
|||
|
||||
### Assembler
|
||||
|
||||
[Assembler](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs) is the trait for generating assembly bytes.
|
||||
[Assembler](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs) is the trait for generating assembly bytes.
|
||||
It defines a set of RISC-like assembly calls that must be implemented for each architecture.
|
||||
A lot of these calls may not map one to one with actual assembly instructions for each architecture.
|
||||
Instead, they are a general abstraction over functionality shared between all architectures.
|
||||
This will grow regularly as more Roc builtins are added.
|
||||
Here are example implementations for [arm](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/aarch64.rs) and [x86_64](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/x86_64.rs).
|
||||
Here are example implementations for [arm](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/aarch64.rs) and [x86_64](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/x86_64.rs).
|
||||
|
||||
### CallConv
|
||||
|
||||
[CallConv](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs) is the abstraction over calling conventions.
|
||||
[CallConv](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs) is the abstraction over calling conventions.
|
||||
It deals with register and stack specific information related to passing and returning arguments.
|
||||
Here are example implementations for [arm](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/aarch64.rs) and [x86_64](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/x86_64.rs).
|
||||
Here are example implementations for [arm](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/aarch64.rs) and [x86_64](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/x86_64.rs).
|
||||
|
||||
## Adding New Features
|
||||
|
||||
Adding a new builtin to the dev backend can be pretty simple.
|
||||
Here is [an example](https://github.com/rtfeldman/roc/pull/893/files) of adding `Num.Sub`.
|
||||
Here is [an example](https://github.com/roc-lang/roc/pull/893/files) of adding `Num.Sub`.
|
||||
|
||||
This is the general procedure I follow with some helpful links:
|
||||
|
||||
1. Find a feature that is just n+1.
|
||||
For example, since we already have integers, adding a builtin that functions on them should be n+1.
|
||||
On the other hand, since we don't yet have booleans/conditionals, adding if statements may not yet be n+1.
|
||||
A good place to look for missing features is in the test files for generation in [test_gen](https://github.com/rtfeldman/roc/tree/trunk/compiler/test_gen). Any test that is not enabled for the `gen-dev` feature still needs to be added to the dev backend. Eventually all features should be enabled for the dev backend.
|
||||
A good place to look for missing features is in the test files for generation in [test_gen](https://github.com/roc-lang/roc/tree/trunk/compiler/test_gen). Any test that is not enabled for the `gen-dev` feature still needs to be added to the dev backend. Eventually all features should be enabled for the dev backend.
|
||||
1. Pick/write the simplest test case you can find for the new feature.
|
||||
Just add `feature = "gen-dev"` to the `cfg` line for the test case.
|
||||
1. Uncomment the code to print out procedures [from here](https://github.com/rtfeldman/roc/blob/b03ed18553569314a420d5bf1fb0ead4b6b5ecda/compiler/test_gen/src/helpers/dev.rs#L76) and run the test.
|
||||
1. Uncomment the code to print out procedures [from here](https://github.com/roc-lang/roc/blob/b03ed18553569314a420d5bf1fb0ead4b6b5ecda/compiler/test_gen/src/helpers/dev.rs#L76) and run the test.
|
||||
It should fail and print out the mono ir for this test case.
|
||||
Seeing the actual mono ir tends to be very helpful for complex additions.
|
||||
1. Generally it will fail in one of the match statements in the [Backend](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/lib.rs) trait.
|
||||
1. Generally it will fail in one of the match statements in the [Backend](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/lib.rs) trait.
|
||||
Add the correct pattern matching and likely new function for your new builtin.
|
||||
This will break the compile until you add the same function to places that implement the trait,
|
||||
like [Backend64Bit](https://github.com/rtfeldman/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs).
|
||||
like [Backend64Bit](https://github.com/roc-lang/roc/blob/trunk/compiler/gen_dev/src/generic64/mod.rs).
|
||||
1. Keep following the chain down.
|
||||
To implement the function in Backend64Bit, you may need to add new assembly calls.
|
||||
Feel free to ignore backends that aren't x86_64 for now and just add `unimplemented!`.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant, clippy::upper_case_acronyms)]
|
||||
|
||||
use bumpalo::{collections::Vec, Bump};
|
||||
|
|
|
@ -172,7 +172,7 @@ fn build_object<'a, B: Backend<'a>>(
|
|||
let arena = backend.env().arena;
|
||||
|
||||
/*
|
||||
// Commented out because we couldn't figure out how to get it to work on mac - see https://github.com/rtfeldman/roc/pull/1323
|
||||
// Commented out because we couldn't figure out how to get it to work on mac - see https://github.com/roc-lang/roc/pull/1323
|
||||
let comment = output.add_section(vec![], b".comment".to_vec(), SectionKind::OtherString);
|
||||
output.append_section_data(
|
||||
comment,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
// we actually want to compare against the literal float bits
|
||||
#![allow(clippy::float_cmp)]
|
||||
|
|
|
@ -3881,7 +3881,7 @@ pub fn get_sjlj_buffer<'a, 'ctx, 'env>(env: &Env<'a, 'ctx, 'env>) -> PointerValu
|
|||
pub fn build_setjmp_call<'a, 'ctx, 'env>(env: &Env<'a, 'ctx, 'env>) -> BasicValueEnum<'ctx> {
|
||||
let jmp_buf = get_sjlj_buffer(env);
|
||||
if cfg!(target_arch = "aarch64") {
|
||||
// Due to https://github.com/rtfeldman/roc/issues/2965, we use a setjmp we linked in from Zig
|
||||
// Due to https://github.com/roc-lang/roc/issues/2965, we use a setjmp we linked in from Zig
|
||||
call_bitcode_fn(env, &[jmp_buf.into()], bitcode::UTILS_SETJMP)
|
||||
} else {
|
||||
// Anywhere else, use the LLVM intrinsic.
|
||||
|
|
|
@ -361,7 +361,7 @@ impl<'ctx> RocUnion<'ctx> {
|
|||
// set the tag id
|
||||
//
|
||||
// NOTE: setting the tag id initially happened before writing the data into it.
|
||||
// That turned out to expose UB. More info at https://github.com/rtfeldman/roc/issues/3554
|
||||
// That turned out to expose UB. More info at https://github.com/roc-lang/roc/issues/3554
|
||||
if let Some(tag_id) = tag_id {
|
||||
let tag_id_type = match self.tag_type.unwrap() {
|
||||
TagType::I8 => env.context.i8_type(),
|
||||
|
|
|
@ -183,7 +183,7 @@ impl<'a> LowLevelCall<'a> {
|
|||
/// Wrap an integer that should have less than 32 bits, but is represented in Wasm as i32.
|
||||
/// This may seem like deliberately introducing an error!
|
||||
/// But we want all targets to behave the same, and hash algos rely on wrapping.
|
||||
/// Discussion: https://github.com/rtfeldman/roc/pull/2117#discussion_r760723063
|
||||
/// Discussion: https://github.com/roc-lang/roc/pull/2117#discussion_r760723063
|
||||
fn wrap_small_int(&self, backend: &mut WasmBackend<'a>, int_width: IntWidth) {
|
||||
let bits = 8 * int_width.stack_size() as i32;
|
||||
let shift = 32 - bits;
|
||||
|
|
|
@ -358,7 +358,7 @@ pub fn unify(
|
|||
);
|
||||
// At this point we can't do anything with must-implement constraints, since we're no
|
||||
// longer solving. We must assume that they were totally caught during solving.
|
||||
// After we land https://github.com/rtfeldman/roc/issues/3207 this concern should totally
|
||||
// After we land https://github.com/roc-lang/roc/issues/3207 this concern should totally
|
||||
// go away.
|
||||
let _ = must_implement_constraints;
|
||||
// Pools are only used to keep track of variable ranks for generalization purposes.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod docs;
|
||||
pub mod file;
|
||||
|
|
|
@ -699,7 +699,7 @@ fn platform_parse_error() {
|
|||
}
|
||||
|
||||
#[test]
|
||||
// See https://github.com/rtfeldman/roc/issues/2413
|
||||
// See https://github.com/roc-lang/roc/issues/2413
|
||||
fn platform_exposes_main_return_by_pointer_issue() {
|
||||
let modules = vec![
|
||||
(
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant, clippy::upper_case_acronyms)]
|
||||
|
||||
pub mod called_via;
|
||||
|
|
|
@ -1207,7 +1207,7 @@ impl<'a> Procs<'a> {
|
|||
// (We had a bug around this before this system existed!)
|
||||
self.specialized.mark_in_progress(symbol.name(), layout);
|
||||
|
||||
// See https://github.com/rtfeldman/roc/issues/1600
|
||||
// See https://github.com/roc-lang/roc/issues/1600
|
||||
//
|
||||
// The annotation variable is the generic/lifted/top-level annotation.
|
||||
// It is connected to the variables of the function's body
|
||||
|
@ -2482,7 +2482,7 @@ fn patterns_to_when<'a>(
|
|||
// are only stores anyway, no branches.
|
||||
//
|
||||
// NOTE this fails if the pattern contains rigid variables,
|
||||
// see https://github.com/rtfeldman/roc/issues/786
|
||||
// see https://github.com/roc-lang/roc/issues/786
|
||||
// this must be fixed when moving exhaustiveness checking to the new canonical AST
|
||||
for (pattern_var, annotated_mark, pattern) in patterns.into_iter() {
|
||||
if annotated_mark.exhaustive.is_non_exhaustive(env.subs) {
|
||||
|
@ -5849,7 +5849,7 @@ fn register_capturing_closure<'a>(
|
|||
}
|
||||
}
|
||||
Err(_) => {
|
||||
// just allow this. see https://github.com/rtfeldman/roc/issues/1585
|
||||
// just allow this. see https://github.com/roc-lang/roc/issues/1585
|
||||
if captured_symbols.is_empty() {
|
||||
CapturedSymbols::None
|
||||
} else {
|
||||
|
@ -7518,7 +7518,7 @@ fn build_call<'a>(
|
|||
Stmt::Let(assigned, Expr::Call(call), return_layout, hole)
|
||||
}
|
||||
|
||||
/// See https://github.com/rtfeldman/roc/issues/1549
|
||||
/// See https://github.com/roc-lang/roc/issues/1549
|
||||
///
|
||||
/// What happened is that a function has a type error, but the arguments are not processed.
|
||||
/// That means specializations were missing. Normally that is not a problem, but because
|
||||
|
|
|
@ -263,7 +263,7 @@ pub enum Layout<'a> {
|
|||
/// so keep a hash of the record order for disambiguation. This still of course may result
|
||||
/// in collisions, but it's unlikely.
|
||||
///
|
||||
/// See also https://github.com/rtfeldman/roc/issues/2535.
|
||||
/// See also https://github.com/roc-lang/roc/issues/2535.
|
||||
field_order_hash: FieldOrderHash,
|
||||
field_layouts: &'a [Layout<'a>],
|
||||
},
|
||||
|
@ -731,7 +731,7 @@ impl std::fmt::Debug for LambdaSet<'_> {
|
|||
/// By recording the captures layouts this lambda expects in its identifier, we can distinguish
|
||||
/// between such differences when constructing closure capture data.
|
||||
///
|
||||
/// See also https://github.com/rtfeldman/roc/issues/3336.
|
||||
/// See also https://github.com/roc-lang/roc/issues/3336.
|
||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug)]
|
||||
pub struct CapturesNiche<'a>(&'a [Layout<'a>]);
|
||||
|
||||
|
@ -1139,7 +1139,7 @@ impl<'a> LambdaSet<'a> {
|
|||
}
|
||||
ResolvedLambdaSet::Unbound => {
|
||||
// The lambda set is unbound which means it must be unused. Just give it the empty lambda set.
|
||||
// See also https://github.com/rtfeldman/roc/issues/3163.
|
||||
// See also https://github.com/roc-lang/roc/issues/3163.
|
||||
Ok(LambdaSet {
|
||||
set: &[],
|
||||
representation: arena.alloc(Layout::UNIT),
|
||||
|
@ -1239,7 +1239,7 @@ enum ResolvedLambdaSet {
|
|||
OptVariable,
|
||||
),
|
||||
/// TODO: figure out if this can happen in a correct program, or is the result of a bug in our
|
||||
/// compiler. See https://github.com/rtfeldman/roc/issues/3163.
|
||||
/// compiler. See https://github.com/roc-lang/roc/issues/3163.
|
||||
Unbound,
|
||||
}
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant, clippy::upper_case_acronyms)]
|
||||
|
||||
pub mod borrow;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
#[macro_use]
|
||||
|
|
|
@ -173,8 +173,8 @@ mod test_parse {
|
|||
pass/lowest_float.expr,
|
||||
pass/lowest_int.expr,
|
||||
pass/malformed_ident_due_to_underscore.expr,
|
||||
pass/malformed_pattern_field_access.expr, // See https://github.com/rtfeldman/roc/issues/399
|
||||
pass/malformed_pattern_module_name.expr, // See https://github.com/rtfeldman/roc/issues/399
|
||||
pass/malformed_pattern_field_access.expr, // See https://github.com/roc-lang/roc/issues/399
|
||||
pass/malformed_pattern_module_name.expr, // See https://github.com/roc-lang/roc/issues/399
|
||||
pass/minimal_app_header.header,
|
||||
pass/minus_twelve_minus_five.expr,
|
||||
pass/mixed_docs.expr,
|
||||
|
@ -191,7 +191,7 @@ mod test_parse {
|
|||
pass/nested_def_annotation.module,
|
||||
pass/nested_if.expr,
|
||||
pass/nested_module.header,
|
||||
pass/newline_after_equals.expr, // Regression test for https://github.com/rtfeldman/roc/issues/51
|
||||
pass/newline_after_equals.expr, // Regression test for https://github.com/roc-lang/roc/issues/51
|
||||
pass/newline_after_mul.expr,
|
||||
pass/newline_after_sub.expr,
|
||||
pass/newline_and_spaces_before_less_than.expr,
|
||||
|
@ -229,7 +229,7 @@ mod test_parse {
|
|||
pass/parenthetical_var.expr,
|
||||
pass/parse_alias.expr,
|
||||
pass/parse_as_ann.expr,
|
||||
pass/pattern_with_space_in_parens.expr, // https://github.com/rtfeldman/roc/issues/929
|
||||
pass/pattern_with_space_in_parens.expr, // https://github.com/roc-lang/roc/issues/929
|
||||
pass/plus_if.expr,
|
||||
pass/plus_when.expr,
|
||||
pass/pos_inf_float.expr,
|
||||
|
@ -263,7 +263,7 @@ mod test_parse {
|
|||
pass/two_branch_when.expr,
|
||||
pass/two_spaced_def.expr,
|
||||
pass/type_decl_with_underscore.expr,
|
||||
pass/unary_negation_access.expr, // Regression test for https://github.com/rtfeldman/roc/issues/509
|
||||
pass/unary_negation_access.expr, // Regression test for https://github.com/roc-lang/roc/issues/509
|
||||
pass/unary_negation_arg.expr,
|
||||
pass/unary_negation_with_parens.expr,
|
||||
pass/unary_negation.expr,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod can;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
pub mod all;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
use strum_macros::{EnumCount, EnumIter};
|
||||
|
|
|
@ -32,7 +32,7 @@ f = if True then id1 else id2
|
|||
^ f : a -[[id1, id2]] -> a
|
||||
```
|
||||
|
||||
The syntax `-[[id1]]->` can be read as “a function that dispatches to `id1`". Then the arrow `-[[id1, id2]]->` then is “a function that dispatches to `id1`, or `id2`". The tag union `[id1, id2]` can contain payloads to represent the captures of `id1` and `id2`; however, the implications of that are out of scope for this discussion, see [Folkert’s great explanation](https://github.com/rtfeldman/roc/pull/2307#discussion_r777042512) for more information. During compile-time, Roc would attach a run-time examinable tag to the value in each branch of the `f` expression body, representing whether to dispatch to `id1` or `id2`. Whenever `f` is dispatched, that tag is examined to determine exactly which function should be dispatched to. This is “**defunctionalization**”.
|
||||
The syntax `-[[id1]]->` can be read as “a function that dispatches to `id1`". Then the arrow `-[[id1, id2]]->` then is “a function that dispatches to `id1`, or `id2`". The tag union `[id1, id2]` can contain payloads to represent the captures of `id1` and `id2`; however, the implications of that are out of scope for this discussion, see [Folkert’s great explanation](https://github.com/roc-lang/roc/pull/2307#discussion_r777042512) for more information. During compile-time, Roc would attach a run-time examinable tag to the value in each branch of the `f` expression body, representing whether to dispatch to `id1` or `id2`. Whenever `f` is dispatched, that tag is examined to determine exactly which function should be dispatched to. This is “**defunctionalization**”.
|
||||
|
||||
In the presence of [abilities](https://docs.google.com/document/d/1kUh53p1Du3fWP_jZp-sdqwb5C9DuS43YJwXHg1NzETY/edit), lambda sets get more complicated. Now, I can write something like
|
||||
|
||||
|
@ -100,7 +100,7 @@ The unification trace for the call `f (@Foo {})` proceeds as follows. I use `'tN
|
|||
Foo -[[zeroHash] + Foo:hashThunk:1]-> ({} -[[lam1] + Foo:hashThunk:2]-> U64)
|
||||
```
|
||||
|
||||
Now that the specialization lambdas’ type variables point to concrete types, we can resolve the concrete lambdas of `Foo:hashThunk:1` and `Foo:hashThunk:2`. Cool! Let’s do that. We know that
|
||||
Now that the specialization lambdas’ type variables point to concrete types, we can resolve the concrete lambdas of `Foo:hashThunk:1` and `Foo:hashThunk:2`. Cool! Let’s do that. We know that
|
||||
|
||||
```
|
||||
hashThunk = \@Foo {} -> \{} -> 1
|
||||
|
@ -205,46 +205,46 @@ Okay, so first we’ll enumerate some terminology, and the exact algorithm. Then
|
|||
### Some definitions
|
||||
|
||||
- **The region invariant.** Previously we discussed the “region” of a lambda set in a specialization function definition. The way regions are assigned in the compiler follows a very specific ordering and holds a invariant we’ll call the “region invariant”. First, let’s define a procedure for creating function types and assigning regions:
|
||||
|
||||
|
||||
```
|
||||
Type = \region ->
|
||||
Type = \region ->
|
||||
(Type_atom, region)
|
||||
| Type_function region
|
||||
|
||||
|
||||
Type_function = \region ->
|
||||
let left_type, new_region = Type (region + 1)
|
||||
let right_type, new_region = Type (new_region)
|
||||
let func_type = left_type -[Lambda region]-> right_type
|
||||
(func_type, new_region)
|
||||
```
|
||||
|
||||
|
||||
This procedure would create functions that look like the trees(abbreviating `L=Lambda`, `a=atom` below)
|
||||
|
||||
|
||||
```
|
||||
-[L 1]->
|
||||
a a
|
||||
|
||||
|
||||
===
|
||||
|
||||
|
||||
-[L 1]->
|
||||
-[L 2]-> -[L 3]->
|
||||
a a a a
|
||||
|
||||
|
||||
===
|
||||
-[L 1]->
|
||||
-[L 2]-> -[L 5]->
|
||||
-[L 3]-> -[L 4]-> -[L 6]-> -[L 7]->
|
||||
a a a a a a a a
|
||||
```
|
||||
|
||||
|
||||
The invariant is this: for a region `r`, the only functions enclosing `r` have a region number that is less than `r`. Moreover, every region `r' < r`, either the function at `r'` encloses `r`, or is disjoint from `r`.
|
||||
|
||||
|
||||
- **Ambient functions.** For a given lambda set at region `r`, any function that encloses `r` is called an **ambient function** of `r`. The function directly at region `r` is called the **directly ambient function**.
|
||||
|
||||
|
||||
For example, the functions identified by `L 4`, `L 2`, and `L 1` in the last example tree above are all ambient functions of the function identified by `L 4`.
|
||||
|
||||
The region invariant means that the only functions that are ambient of a region `r` are those identified by regions `< r`.
|
||||
|
||||
|
||||
The region invariant means that the only functions that are ambient of a region `r` are those identified by regions `< r`.
|
||||
|
||||
- `uls_of_var`. A look aside table of the unspecialized lambda sets (uls) depending on a variable. For example, in `a -[[] + a:f:1]-> (b -[[] + a:f:2]-> {})`, there would be a mapping of `a => { [[] + a:f:1]; [[] + a:f:2] }`. When `a` gets instantiated with a concrete type, we know that these lambda sets are ready to be resolved.
|
||||
|
||||
### Explicit Description
|
||||
|
@ -440,13 +440,13 @@ F has f : a, b -> ({} -> ({} -> {})) | a has F, b has G
|
|||
# ^ a, b -[[] + a:f:1]-> ({} -[[] + a:f:2]-> ({} -[[] + a:f:3]-> {})) | a has F, b has G
|
||||
G has g : b -> ({} -> {}) | b has G
|
||||
# ^ b -[[] + b:g:1]-> ({} -[[] + b:g:2]-> {}) | b has G
|
||||
|
||||
|
||||
Fo := {}
|
||||
f = \@Fo {}, b -> \{} -> g b
|
||||
#^ Fo, b -[[Fo#f]]-> ({} -[[lamF b]]-> ({} -[[] + b:g:2]]-> {})) | b has G
|
||||
# instantiation with a=Fo of
|
||||
# a, b -[[] + a:f:1]-> ({} -[[] + a:f:2]-> ({} -[[] + a:f:3]-> {})) | a has F, b has G
|
||||
|
||||
|
||||
Go := {}
|
||||
g = \@Go {} -> \{} -> {}
|
||||
#^ {} -[[Go#g]]-> ({} -[[lamG]]-> {})
|
||||
|
@ -670,7 +670,7 @@ You may have observed that step 1 and step 2 of the algorithm are somewhat overk
|
|||
This optimization is correct with a change to the region numbering scheme:
|
||||
|
||||
```python
|
||||
Type = \region ->
|
||||
Type = \region ->
|
||||
(Type_atom, region)
|
||||
| Type_function region
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
pub mod ability;
|
||||
|
|
|
@ -3113,7 +3113,7 @@ fn adjust_rank_content(
|
|||
// inside a lambda set but not on the left or right of an arrow, and records should not
|
||||
// force de-generalization in such cases.
|
||||
//
|
||||
// See https://github.com/rtfeldman/roc/issues/3641 for a longer discussion and
|
||||
// See https://github.com/roc-lang/roc/issues/3641 for a longer discussion and
|
||||
// example.
|
||||
group_rank
|
||||
}
|
||||
|
|
|
@ -4916,7 +4916,7 @@ mod solve_expr {
|
|||
|
||||
#[test]
|
||||
fn rigid_type_variable_problem() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1162
|
||||
// see https://github.com/roc-lang/roc/issues/1162
|
||||
infer_eq_without_problem(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -5024,7 +5024,7 @@ mod solve_expr {
|
|||
#[test]
|
||||
fn inference_var_tag_union_ext() {
|
||||
// TODO: we should really be inferring [Blue, Orange]a -> [Lavender, Peach]a here.
|
||||
// See https://github.com/rtfeldman/roc/issues/2053
|
||||
// See https://github.com/roc-lang/roc/issues/2053
|
||||
infer_eq_without_problem(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -5491,7 +5491,7 @@ mod solve_expr {
|
|||
)
|
||||
}
|
||||
|
||||
// https://github.com/rtfeldman/roc/issues/2379
|
||||
// https://github.com/roc-lang/roc/issues/2379
|
||||
#[test]
|
||||
fn copy_vars_referencing_copied_vars() {
|
||||
infer_eq_without_problem(
|
||||
|
@ -5866,7 +5866,7 @@ mod solve_expr {
|
|||
}
|
||||
|
||||
#[test]
|
||||
// https://github.com/rtfeldman/roc/issues/2702
|
||||
// https://github.com/roc-lang/roc/issues/2702
|
||||
fn tag_inclusion_behind_opaque() {
|
||||
infer_eq_without_problem(
|
||||
indoc!(
|
||||
|
|
|
@ -468,9 +468,9 @@ mod encode_immediate {
|
|||
17, u32
|
||||
17, u64
|
||||
17, u128
|
||||
// 17.23, f32 TODO https://github.com/rtfeldman/roc/issues/3522
|
||||
// 17.23, f32 TODO https://github.com/roc-lang/roc/issues/3522
|
||||
17.23, f64
|
||||
// 17.23, dec TODO https://github.com/rtfeldman/roc/issues/3522
|
||||
// 17.23, dec TODO https://github.com/roc-lang/roc/issues/3522
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -2831,7 +2831,7 @@ fn lists_with_incompatible_type_param_in_if() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn map_with_index_multi_record() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1700
|
||||
// see https://github.com/roc-lang/roc/issues/1700
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2846,7 +2846,7 @@ fn map_with_index_multi_record() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn empty_list_of_function_type() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1732
|
||||
// see https://github.com/roc-lang/roc/issues/1732
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -3276,7 +3276,7 @@ fn monomorphized_lists() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn with_capacity() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1732
|
||||
// see https://github.com/roc-lang/roc/issues/1732
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
|
|
@ -3567,7 +3567,7 @@ fn to_float_f64() {
|
|||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
// https://github.com/rtfeldman/roc/issues/2696
|
||||
// https://github.com/roc-lang/roc/issues/2696
|
||||
fn upcast_of_int_is_zext() {
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
|
@ -3582,7 +3582,7 @@ fn upcast_of_int_is_zext() {
|
|||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
// https://github.com/rtfeldman/roc/issues/2696
|
||||
// https://github.com/roc-lang/roc/issues/2696
|
||||
fn upcast_of_int_checked_is_zext() {
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
|
|
|
@ -2643,12 +2643,12 @@ fn pattern_match_unit_tag() {
|
|||
);
|
||||
}
|
||||
|
||||
// see for why this is disabled on wasm32 https://github.com/rtfeldman/roc/issues/1687
|
||||
// see for why this is disabled on wasm32 https://github.com/roc-lang/roc/issues/1687
|
||||
#[cfg(not(feature = "gen-llvm-wasm"))]
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn mirror_llvm_alignment_padding() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1569
|
||||
// see https://github.com/roc-lang/roc/issues/1569
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2781,7 +2781,7 @@ fn lambda_set_enum_byte_byte() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn list_walk_until() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1576
|
||||
// see https://github.com/roc-lang/roc/issues/1576
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2807,7 +2807,7 @@ fn list_walk_until() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn int_literal_not_specialized_with_annotation() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1600
|
||||
// see https://github.com/roc-lang/roc/issues/1600
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2835,7 +2835,7 @@ fn int_literal_not_specialized_with_annotation() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn int_literal_not_specialized_no_annotation() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1600
|
||||
// see https://github.com/roc-lang/roc/issues/1600
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2862,7 +2862,7 @@ fn int_literal_not_specialized_no_annotation() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn unresolved_tvar_when_capture_is_unused() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1585
|
||||
// see https://github.com/roc-lang/roc/issues/1585
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2908,7 +2908,7 @@ fn value_not_exposed_hits_panic() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn mix_function_and_closure() {
|
||||
// see https://github.com/rtfeldman/roc/pull/1706
|
||||
// see https://github.com/roc-lang/roc/pull/1706
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2934,7 +2934,7 @@ fn mix_function_and_closure() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn mix_function_and_closure_level_of_indirection() {
|
||||
// see https://github.com/rtfeldman/roc/pull/1706
|
||||
// see https://github.com/roc-lang/roc/pull/1706
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -2960,7 +2960,7 @@ fn mix_function_and_closure_level_of_indirection() {
|
|||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
#[cfg_attr(debug_assertions, ignore)] // this test stack-overflows the compiler in debug mode
|
||||
fn do_pass_bool_byte_closure_layout() {
|
||||
// see https://github.com/rtfeldman/roc/pull/1706
|
||||
// see https://github.com/roc-lang/roc/pull/1706
|
||||
// the distinction is actually important, dropping that info means some functions just get
|
||||
// skipped
|
||||
assert_evals_to!(
|
||||
|
@ -3422,7 +3422,7 @@ fn polymorphic_lambda_set_multiple_specializations() {
|
|||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn list_map2_conslist() {
|
||||
// this had an RC problem, https://github.com/rtfeldman/roc/issues/2968
|
||||
// this had an RC problem, https://github.com/roc-lang/roc/issues/2968
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
r#"
|
||||
|
|
|
@ -964,7 +964,7 @@ fn update_the_only_field() {
|
|||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
// https://github.com/rtfeldman/roc/issues/1513
|
||||
// https://github.com/roc-lang/roc/issues/1513
|
||||
fn both_have_unique_fields() {
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
|
@ -985,7 +985,7 @@ fn both_have_unique_fields() {
|
|||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
// https://github.com/rtfeldman/roc/issues/2535
|
||||
// https://github.com/roc-lang/roc/issues/2535
|
||||
fn different_proc_types_specialized_to_same_layout() {
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
|
|
|
@ -1154,7 +1154,7 @@ fn applied_tag_function_result() {
|
|||
|
||||
#[test]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
#[ignore = "This test has incorrect refcounts: https://github.com/rtfeldman/roc/issues/2968"]
|
||||
#[ignore = "This test has incorrect refcounts: https://github.com/roc-lang/roc/issues/2968"]
|
||||
fn applied_tag_function_linked_list() {
|
||||
assert_evals_to!(
|
||||
indoc!(
|
||||
|
@ -1469,7 +1469,7 @@ fn issue_2458() {
|
|||
}
|
||||
|
||||
#[test]
|
||||
#[ignore = "See https://github.com/rtfeldman/roc/issues/2466"]
|
||||
#[ignore = "See https://github.com/roc-lang/roc/issues/2466"]
|
||||
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
|
||||
fn issue_2458_deep_recursion_var() {
|
||||
assert_evals_to!(
|
||||
|
@ -1921,10 +1921,10 @@ fn issue_2165_recursive_tag_destructure() {
|
|||
indoc!(
|
||||
r#"
|
||||
SomeTag : [ Ctor { rec : List SomeTag } ]
|
||||
|
||||
|
||||
x : SomeTag
|
||||
x = Ctor { rec: [] }
|
||||
|
||||
|
||||
when x is
|
||||
Ctor { rec } -> Num.toStr (List.len rec)
|
||||
"#
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
// we actually want to compare against the literal float bits
|
||||
#![allow(clippy::float_cmp)]
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#![cfg(test)]
|
||||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
// we actually want to compare against the literal float bits
|
||||
#![allow(clippy::float_cmp)]
|
||||
|
@ -1084,7 +1084,7 @@ fn specialize_lowlevel() {
|
|||
|
||||
#[mono_test]
|
||||
fn empty_list_of_function_type() {
|
||||
// see https://github.com/rtfeldman/roc/issues/1732
|
||||
// see https://github.com/roc-lang/roc/issues/1732
|
||||
indoc!(
|
||||
r#"
|
||||
app "test" provides [main] to "./platform"
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
pub mod num;
|
||||
pub mod pretty_print;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
pub mod unify;
|
||||
|
|
|
@ -1005,7 +1005,7 @@ fn unify_lambda_set<M: MetaCollector>(
|
|||
FlexVar(_) => {
|
||||
if M::UNIFYING_SPECIALIZATION {
|
||||
// TODO: It appears that this can happen in well-typed, reasonable programs, but it's
|
||||
// open question as to why! See also https://github.com/rtfeldman/roc/issues/3163.
|
||||
// open question as to why! See also https://github.com/roc-lang/roc/issues/3163.
|
||||
let zero_lambda_set = LambdaSet {
|
||||
solved: UnionLabels::default(),
|
||||
recursion_var: OptVariable::NONE,
|
||||
|
@ -1209,7 +1209,7 @@ fn separate_union_lambdas<M: MetaCollector>(
|
|||
// Lambda sets are effectively tags under another name, and their usage can also result
|
||||
// in the arguments of a lambda name being recursive. It very well may happen that
|
||||
// during unification, a lambda set previously marked as not recursive becomes
|
||||
// recursive. See the docs of [LambdaSet] for one example, or https://github.com/rtfeldman/roc/pull/2307.
|
||||
// recursive. See the docs of [LambdaSet] for one example, or https://github.com/roc-lang/roc/pull/2307.
|
||||
//
|
||||
// Like with tag unions, if it has, we'll always pass through this branch. So, take
|
||||
// this opportunity to promote the lambda set to recursive if need be.
|
||||
|
|
|
@ -23,7 +23,7 @@ If you encounter an error like `gfx_backend_vulkan ... Failed to detect any vali
|
|||
If the error persists, take a look [here](https://www.techpowerup.com/gpu-specs/) to see if your GPU supports vulkan.
|
||||
Use of OpenGL instead of vulkan should be available in several months.
|
||||
|
||||
Make sure to [create an issue](https://github.com/rtfeldman/roc/issues/new/choose) if you encounter any problems not listed above.
|
||||
Make sure to [create an issue](https://github.com/roc-lang/roc/issues/new/choose) if you encounter any problems not listed above.
|
||||
|
||||
## Inspiration
|
||||
|
||||
|
|
|
@ -414,7 +414,7 @@ async fn create_device(
|
|||
})
|
||||
.await
|
||||
.expect(r#"Request adapter
|
||||
If you're running this from inside nix, follow the instructions here to resolve this: https://github.com/rtfeldman/roc/blob/trunk/BUILDING_FROM_SOURCE.md#editor
|
||||
If you're running this from inside nix, follow the instructions here to resolve this: https://github.com/roc-lang/roc/blob/trunk/BUILDING_FROM_SOURCE.md#editor
|
||||
"#);
|
||||
|
||||
let color_format = surface.get_preferred_format(&adapter).unwrap();
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant, clippy::upper_case_acronyms)]
|
||||
|
||||
#[cfg_attr(test, macro_use)]
|
||||
|
|
|
@ -9,7 +9,7 @@ macro_rules! internal_error {
|
|||
eprintln!("An internal compiler expectation was broken.");
|
||||
eprintln!("This is definitely a compiler bug.");
|
||||
// TODO: update this to the new bug template.
|
||||
eprintln!("Please file an issue here: https://github.com/rtfeldman/roc/issues/new/choose");
|
||||
eprintln!("Please file an issue here: https://github.com/roc-lang/roc/issues/new/choose");
|
||||
#[allow(clippy::panic)] {
|
||||
panic!($($arg)*);
|
||||
}
|
||||
|
@ -92,13 +92,13 @@ macro_rules! assert_copyable {
|
|||
macro_rules! _incomplete_project {
|
||||
($project_name:literal, $tracking_issue_no:literal) => {
|
||||
panic!(
|
||||
"[{}] not yet implemented. Tracking issue: https://github.com/rtfeldman/roc/issues/{}",
|
||||
"[{}] not yet implemented. Tracking issue: https://github.com/roc-lang/roc/issues/{}",
|
||||
$project_name, $tracking_issue_no,
|
||||
)
|
||||
};
|
||||
($project_name:literal, $tracking_issue_no:literal, $($arg:tt)+) => {
|
||||
panic!(
|
||||
"[{}] not yet implemented. Tracking issue: https://github.com/rtfeldman/roc/issues/{}.\nAdditional information: {}",
|
||||
"[{}] not yet implemented. Tracking issue: https://github.com/roc-lang/roc/issues/{}.\nAdditional information: {}",
|
||||
$project_name, $tracking_issue_no,
|
||||
format_args!($($arg)+),
|
||||
)
|
||||
|
|
|
@ -3,7 +3,7 @@ name = "roc_linker"
|
|||
version = "0.0.1"
|
||||
authors = ["The Roc Contributors"]
|
||||
license = "UPL-1.0"
|
||||
repository = "https://github.com/rtfeldman/roc"
|
||||
repository = "https://github.com/roc-lang/roc"
|
||||
edition = "2021"
|
||||
description = "A surgical linker for Roc"
|
||||
|
||||
|
|
|
@ -19,8 +19,8 @@ bumpalo = {version = "3.8.0", features = ["collections"]}
|
|||
const_format = { version = "0.2.23", features = ["const_generics"] }
|
||||
inkwell = {path = "../vendor/inkwell"}
|
||||
libloading = "0.7.1"
|
||||
rustyline = {git = "https://github.com/rtfeldman/rustyline", rev = "e74333c"}
|
||||
rustyline-derive = {git = "https://github.com/rtfeldman/rustyline", rev = "e74333c"}
|
||||
rustyline = {git = "https://github.com/roc-lang/rustyline", rev = "e74333c"}
|
||||
rustyline-derive = {git = "https://github.com/roc-lang/rustyline", rev = "e74333c"}
|
||||
target-lexicon = "0.12.2"
|
||||
|
||||
roc_build = {path = "../compiler/build"}
|
||||
|
|
|
@ -120,7 +120,7 @@ pub fn type_problem<'b>(
|
|||
report(title, doc, filename)
|
||||
}
|
||||
|
||||
SolvedTypeError => None, // Don't re-report cascading errors - see https://github.com/rtfeldman/roc/pull/1711
|
||||
SolvedTypeError => None, // Don't re-report cascading errors - see https://github.com/roc-lang/roc/pull/1711
|
||||
|
||||
// We'll also report these as a canonicalization problem, no need to re-report them.
|
||||
CyclicAlias(..) => None,
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
#![warn(clippy::dbg_macro)]
|
||||
// See github.com/rtfeldman/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
// See github.com/roc-lang/roc/issues/800 for discussion of the large_enum_variant check.
|
||||
#![allow(clippy::large_enum_variant)]
|
||||
|
||||
pub mod error;
|
||||
|
|
|
@ -552,7 +552,7 @@ mod test_reporting {
|
|||
);
|
||||
|
||||
test_report!(
|
||||
#[ignore = "Blocked on https://github.com/rtfeldman/roc/issues/3385"]
|
||||
#[ignore = "Blocked on https://github.com/roc-lang/roc/issues/3385"]
|
||||
unrecognized_name,
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -5245,7 +5245,7 @@ mod test_reporting {
|
|||
"###
|
||||
);
|
||||
|
||||
// https://github.com/rtfeldman/roc/issues/1714
|
||||
// https://github.com/roc-lang/roc/issues/1714
|
||||
test_report!(
|
||||
interpolate_concat_is_transparent_1714,
|
||||
indoc!(
|
||||
|
@ -7570,7 +7570,7 @@ All branches in an `if` must have the same type!
|
|||
);
|
||||
|
||||
test_report!(
|
||||
#[ignore = "Blocked on https://github.com/rtfeldman/roc/issues/3385"]
|
||||
#[ignore = "Blocked on https://github.com/roc-lang/roc/issues/3385"]
|
||||
unimported_modules_reported,
|
||||
indoc!(
|
||||
r#"
|
||||
|
@ -8843,7 +8843,7 @@ All branches in an `if` must have the same type!
|
|||
"#
|
||||
);
|
||||
|
||||
// from https://github.com/rtfeldman/roc/commit/1372737f5e53ee5bb96d7e1b9593985e5537023a
|
||||
// from https://github.com/roc-lang/roc/commit/1372737f5e53ee5bb96d7e1b9593985e5537023a
|
||||
// There was a bug where this reported UnusedArgument("val")
|
||||
// since it was used only in the returned function only.
|
||||
//
|
||||
|
@ -9123,7 +9123,7 @@ All branches in an `if` must have the same type!
|
|||
"#
|
||||
),
|
||||
// TODO: this error message is quite unfortunate. We should remove the duplication, and
|
||||
// also support regions that point to things in other modules. See also https://github.com/rtfeldman/roc/issues/3056.
|
||||
// also support regions that point to things in other modules. See also https://github.com/roc-lang/roc/issues/3056.
|
||||
@r###"
|
||||
── TYPE MISMATCH ───────────────────────────────────────── /code/proj/Main.roc ─
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ edition = "2021"
|
|||
license = "UPL-1.0"
|
||||
name = "roc_std"
|
||||
readme = "README.md"
|
||||
repository = "https://github.com/rtfeldman/roc"
|
||||
repository = "https://github.com/roc-lang/roc"
|
||||
version = "0.0.1"
|
||||
|
||||
[dependencies]
|
||||
|
|
8
crates/vendor/inkwell/Cargo.toml
vendored
8
crates/vendor/inkwell/Cargo.toml
vendored
|
@ -6,7 +6,7 @@ license = "UPL-1.0"
|
|||
edition = "2018"
|
||||
|
||||
[dependencies]
|
||||
# NOTE: rtfeldman/inkwell is a fork of TheDan64/inkwell which does not change anything.
|
||||
# NOTE: roc-lang/inkwell is a fork of TheDan64/inkwell which does not change anything.
|
||||
#
|
||||
# The reason for this fork is that the way Inkwell is designed, you have to use
|
||||
# a particular branch (e.g. "llvm8-0") in Cargo.toml. That would be fine, except that
|
||||
|
@ -16,14 +16,14 @@ edition = "2018"
|
|||
# We tried referencing a specific rev on TheDan64/inkwell directly (instead of branch),
|
||||
# but although that worked locally, it did not work on GitHub Actions. (After a few
|
||||
# hours of investigation, gave up trying to figure out why.) So this is the workaround:
|
||||
# having an immutable tag on the rtfeldman/inkwell fork which points to
|
||||
# having an immutable tag on the roc-lang/inkwell fork which points to
|
||||
# a particular "release" of Inkwell.
|
||||
#
|
||||
# When we want to update Inkwell, we can sync up rtfeldman/inkwell to the latest
|
||||
# When we want to update Inkwell, we can sync up roc-lang/inkwell to the latest
|
||||
# commit of TheDan64/inkwell, push a new tag which points to the latest commit,
|
||||
# change the tag value in this Cargo.toml to point to that tag, and `cargo update`.
|
||||
# This way, GitHub Actions works and nobody's builds get broken.
|
||||
inkwell = { git = "https://github.com/rtfeldman/inkwell", branch = "master", features = [ "llvm13-0" ] }
|
||||
inkwell = { git = "https://github.com/roc-lang/inkwell", branch = "master", features = [ "llvm13-0" ] }
|
||||
|
||||
[features]
|
||||
target-arm = []
|
||||
|
|
|
@ -4,5 +4,5 @@ description = "Rust wrapper for a WebAssembly test platform built on libc"
|
|||
edition = "2021"
|
||||
license = "UPL-1.0"
|
||||
name = "wasi_libc_sys"
|
||||
repository = "https://github.com/rtfeldman/roc"
|
||||
repository = "https://github.com/roc-lang/roc"
|
||||
version = "0.0.1"
|
||||
|
|
|
@ -3,7 +3,7 @@ app "closure"
|
|||
imports [pf.Task]
|
||||
provides [main] to pf
|
||||
|
||||
# see https://github.com/rtfeldman/roc/issues/985
|
||||
# see https://github.com/roc-lang/roc/issues/985
|
||||
main : Task.Task {} []
|
||||
main = closure1 {}
|
||||
# |> Task.after (\_ -> closure2 {})
|
||||
|
|
|
@ -64,7 +64,7 @@ none : Elem *
|
|||
none = None # I've often wanted this in elm/html. Usually end up resorting to (Html.text "") - this seems nicer.
|
||||
## Change an element's state type.
|
||||
##
|
||||
## TODO: indent the following once https://github.com/rtfeldman/roc/issues/2585 is fixed.
|
||||
## TODO: indent the following once https://github.com/roc-lang/roc/issues/2585 is fixed.
|
||||
## State : { photo : Photo }
|
||||
##
|
||||
## render : State -> Elem State
|
||||
|
@ -113,7 +113,7 @@ translate = \child, toChild, toParent ->
|
|||
## Convenient when you have a [List] in your state and want to make
|
||||
## a [List] of child elements out of it.
|
||||
##
|
||||
## TODO: indent the following once https://github.com/rtfeldman/roc/issues/2585 is fixed.
|
||||
## TODO: indent the following once https://github.com/roc-lang/roc/issues/2585 is fixed.
|
||||
## State : { photos : List Photo }
|
||||
##
|
||||
## render : State -> Elem State
|
||||
|
@ -123,7 +123,7 @@ translate = \child, toChild, toParent ->
|
|||
## Elem.list Photo.render state .photos &photos
|
||||
##
|
||||
## col {} children
|
||||
## TODO: format as multiline type annotation once https://github.com/rtfeldman/roc/issues/2586 is fixed
|
||||
## TODO: format as multiline type annotation once https://github.com/roc-lang/roc/issues/2586 is fixed
|
||||
list : (child -> Elem child), parent, (parent -> List child), (parent, List child -> parent) -> List (Elem parent)
|
||||
list = \renderChild, parent, toChildren, toParent ->
|
||||
List.mapWithIndex
|
||||
|
@ -147,7 +147,7 @@ list = \renderChild, parent, toChildren, toParent ->
|
|||
## if the child has been removed from the parent,
|
||||
## drops it.
|
||||
##
|
||||
## TODO: format as multiline type annotation once https://github.com/rtfeldman/roc/issues/2586 is fixed
|
||||
## TODO: format as multiline type annotation once https://github.com/roc-lang/roc/issues/2586 is fixed
|
||||
translateOrDrop : Elem child, (parent -> Result child *), (parent, child -> parent) -> Elem parent
|
||||
translateOrDrop = \child, toChild, toParent ->
|
||||
when child is
|
||||
|
|
|
@ -73,7 +73,7 @@ pub fn run_event_loop(title: &str, window_bounds: Bounds) -> Result<(), Box<dyn
|
|||
})
|
||||
.await
|
||||
.expect(r#"Request adapter
|
||||
If you're running this from inside nix, follow the instructions here to resolve this: https://github.com/rtfeldman/roc/blob/trunk/BUILDING_FROM_SOURCE.md#editor
|
||||
If you're running this from inside nix, follow the instructions here to resolve this: https://github.com/roc-lang/roc/blob/trunk/BUILDING_FROM_SOURCE.md#editor
|
||||
"#);
|
||||
|
||||
adapter
|
||||
|
|
|
@ -64,7 +64,7 @@ none : Elem *
|
|||
none = None # I've often wanted this in elm/html. Usually end up resorting to (Html.text "") - this seems nicer.
|
||||
## Change an element's state type.
|
||||
##
|
||||
## TODO: indent the following once https://github.com/rtfeldman/roc/issues/2585 is fixed.
|
||||
## TODO: indent the following once https://github.com/roc-lang/roc/issues/2585 is fixed.
|
||||
## State : { photo : Photo }
|
||||
##
|
||||
## render : State -> Elem State
|
||||
|
@ -113,7 +113,7 @@ translate = \child, toChild, toParent ->
|
|||
## Convenient when you have a [List] in your state and want to make
|
||||
## a [List] of child elements out of it.
|
||||
##
|
||||
## TODO: indent the following once https://github.com/rtfeldman/roc/issues/2585 is fixed.
|
||||
## TODO: indent the following once https://github.com/roc-lang/roc/issues/2585 is fixed.
|
||||
## State : { photos : List Photo }
|
||||
##
|
||||
## render : State -> Elem State
|
||||
|
@ -123,7 +123,7 @@ translate = \child, toChild, toParent ->
|
|||
## Elem.list Photo.render state .photos &photos
|
||||
##
|
||||
## col {} children
|
||||
## TODO: format as multiline type annotation once https://github.com/rtfeldman/roc/issues/2586 is fixed
|
||||
## TODO: format as multiline type annotation once https://github.com/roc-lang/roc/issues/2586 is fixed
|
||||
list : (child -> Elem child), parent, (parent -> List child), (parent, List child -> parent) -> List (Elem parent)
|
||||
list = \renderChild, parent, toChildren, toParent ->
|
||||
List.mapWithIndex
|
||||
|
@ -147,7 +147,7 @@ list = \renderChild, parent, toChildren, toParent ->
|
|||
## if the child has been removed from the parent,
|
||||
## drops it.
|
||||
##
|
||||
## TODO: format as multiline type annotation once https://github.com/rtfeldman/roc/issues/2586 is fixed
|
||||
## TODO: format as multiline type annotation once https://github.com/roc-lang/roc/issues/2586 is fixed
|
||||
translateOrDrop : Elem child, (parent -> Result child *), (parent, child -> parent) -> Elem parent
|
||||
translateOrDrop = \child, toChild, toParent ->
|
||||
when child is
|
||||
|
|
|
@ -56,7 +56,7 @@ fn run_event_loop(title: &str, root: RocElem) -> Result<(), Box<dyn Error>> {
|
|||
})
|
||||
.await
|
||||
.expect(r#"Request adapter
|
||||
If you're running this from inside nix, follow the instructions here to resolve this: https://github.com/rtfeldman/roc/blob/trunk/BUILDING_FROM_SOURCE.md#editor
|
||||
If you're running this from inside nix, follow the instructions here to resolve this: https://github.com/roc-lang/roc/blob/trunk/BUILDING_FROM_SOURCE.md#editor
|
||||
"#);
|
||||
|
||||
adapter
|
||||
|
|
|
@ -108,7 +108,7 @@
|
|||
zlib
|
||||
libiconv
|
||||
|
||||
# faster builds - see https://github.com/rtfeldman/roc/blob/trunk/BUILDING_FROM_SOURCE.md#use-lld-for-the-linker
|
||||
# faster builds - see https://github.com/roc-lang/roc/blob/trunk/BUILDING_FROM_SOURCE.md#use-lld-for-the-linker
|
||||
llvmPkgs.lld
|
||||
debugir
|
||||
rust
|
||||
|
|
|
@ -4,9 +4,9 @@ Roc is a language for making delightful software. It does not have an 0.1 releas
|
|||
certainly don't recommend using it in production in its current state! However, it can be fun to
|
||||
play around with as long as you have a high tolerance for missing features and compiler bugs. :)
|
||||
|
||||
The [tutorial](TUTORIAL.md) is the best place to learn about how to use the language - it assumes no prior knowledge of Roc or similar languages. (If you already know [Elm](https://elm-lang.org/), then [Roc for Elm Programmers](https://github.com/rtfeldman/roc/blob/trunk/roc-for-elm-programmers.md) may be of interest.)
|
||||
The [tutorial](TUTORIAL.md) is the best place to learn about how to use the language - it assumes no prior knowledge of Roc or similar languages. (If you already know [Elm](https://elm-lang.org/), then [Roc for Elm Programmers](https://github.com/roc-lang/roc/blob/trunk/roc-for-elm-programmers.md) may be of interest.)
|
||||
|
||||
There's also a folder of [examples](https://github.com/rtfeldman/roc/tree/trunk/examples) - the [CLI form example](https://github.com/rtfeldman/roc/tree/trunk/examples/interactive/form.roc) in particular is a reasonable starting point to build on.
|
||||
There's also a folder of [examples](https://github.com/roc-lang/roc/tree/trunk/examples) - the [CLI form example](https://github.com/roc-lang/roc/tree/trunk/examples/interactive/form.roc) in particular is a reasonable starting point to build on.
|
||||
|
||||
If you have a specific question, the [FAQ](FAQ.md) might have an answer, although [Roc Zulip chat](https://roc.zulipchat.com) is overall the best place to ask questions and get help! It's also where we discuss [ideas](https://roc.zulipchat.com/#narrow/stream/304641-ideas) for the language. If you want to get involved in contributing to the language, Zulip is also a great place to ask about good first projects.
|
||||
|
||||
|
@ -43,4 +43,4 @@ never done anything with Rust and also never worked on a compiler, but we've
|
|||
been able to find beginner-friendly projects to get people up to speed gradually.)
|
||||
|
||||
If you're interested in getting involved, check out
|
||||
[CONTRIBUTING.md](https://github.com/rtfeldman/roc/blob/trunk/CONTRIBUTING.md)!
|
||||
[CONTRIBUTING.md](https://github.com/roc-lang/roc/blob/trunk/CONTRIBUTING.md)!
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
0. Download the latest nightly from the assets [here](https://github.com/rtfeldman/roc/releases).
|
||||
0. Download the latest nightly from the assets [here](https://github.com/roc-lang/roc/releases).
|
||||
0. Untar the archive:
|
||||
```
|
||||
tar -xf roc_nightly-linux_x86_64-<VERSION>.tar.gz
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
0. Download the latest nightly from the assets [here](https://github.com/rtfeldman/roc/releases).
|
||||
0. Download the latest nightly from the assets [here](https://github.com/roc-lang/roc/releases).
|
||||
0. To prevent "roc can't be opened because Apple can't check it...":
|
||||
```
|
||||
xattr -d com.apple.quarantine roc_nightly-darwin_apple_silicon-<VERSION>.tar.gz
|
||||
xattr -d com.apple.quarantine roc_nightly-darwin_apple_silicon-<VERSION>.tar.gz
|
||||
```
|
||||
0. Untar the archive:
|
||||
```
|
||||
roc_nightly-darwin_apple_silicon-<VERSION>.tar.gz
|
||||
roc_nightly-darwin_apple_silicon-<VERSION>.tar.gz
|
||||
```
|
||||
0. To be able to run examples:
|
||||
- for the Rust example:
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
0. Download the latest nightly from the assets [here](https://github.com/rtfeldman/roc/releases).
|
||||
0. Download the latest nightly from the assets [here](https://github.com/roc-lang/roc/releases).
|
||||
0. To prevent "roc can't be opened because Apple can't check it...":
|
||||
```
|
||||
xattr -d com.apple.quarantine roc_nightly-macos_x86_64-<VERSION>.tar.gz
|
||||
xattr -d com.apple.quarantine roc_nightly-macos_x86_64-<VERSION>.tar.gz
|
||||
```
|
||||
0. Untar the archive:
|
||||
```
|
||||
roc_nightly-macos_x86_64-<VERSION>.tar.gz
|
||||
roc_nightly-macos_x86_64-<VERSION>.tar.gz
|
||||
```
|
||||
0. To be able to run examples:
|
||||
- for the Rust example:
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
Windows is not yet supported, we have a big project in the works (see [issue #2608](https://github.com/rtfeldman/roc/issues/2608)) that will allow this.
|
||||
Windows is not yet supported, we have a big project in the works (see [issue #2608](https://github.com/roc-lang/roc/issues/2608)) that will allow this.
|
||||
Until then we recommend using Ubuntu through the "Windows Subsystem for Linux".
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue