Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
372 commits
Select commit Hold shift + click to select a range
ca97306
introduce NameResolution wrapper struct
nikomatsakis Oct 23, 2024
c67989c
rework AstPath to be an enum
nikomatsakis Oct 24, 2024
7e3c6aa
checkpoint
nikomatsakis Oct 24, 2024
3561fe0
checkpoint
nikomatsakis Oct 25, 2024
f3a60fd
checkpoint
nikomatsakis Oct 25, 2024
c0c29c5
checkpoint
nikomatsakis Oct 26, 2024
7983b60
checkpoint
nikomatsakis Oct 26, 2024
8f4087b
typing rules for operators
nikomatsakis Oct 26, 2024
8cf6c85
checkpoint
nikomatsakis Oct 26, 2024
21134e8
checkpoint
nikomatsakis Oct 27, 2024
95a27f6
miscellany
nikomatsakis Oct 27, 2024
86b5b87
use `.ansi` suffix and include ansi colors
nikomatsakis Oct 27, 2024
e07d0fd
add visibility to functions, classes
nikomatsakis Oct 27, 2024
78eeafc
use more ansi colors
nikomatsakis Oct 27, 2024
1dba026
add the concept of a prelude, start with libdada
nikomatsakis Oct 28, 2024
dccd8d6
fix some spans
nikomatsakis Oct 28, 2024
b15e74b
allowing calling functions (!)
nikomatsakis Oct 28, 2024
7e54d66
placeholder support for futures
nikomatsakis Oct 28, 2024
ed1c208
checkpoint: class constructors
nikomatsakis Oct 29, 2024
44de613
make calling a class equivalent to calling `new`
nikomatsakis Oct 29, 2024
6c25404
desugar `Foo(a: u32)` to a `new` function
nikomatsakis Oct 30, 2024
daa238d
give a span to each spawned task
nikomatsakis Oct 30, 2024
563a79e
attach a span to local variables
nikomatsakis Oct 30, 2024
b2b7ce3
add diagnostics for type annotations needed
nikomatsakis Oct 30, 2024
7c125d8
rename Check to Runtime
nikomatsakis Oct 30, 2024
5e187fd
refactor: just pass env
nikomatsakis Oct 30, 2024
09a00ae
upgrade salsa
nikomatsakis Nov 1, 2024
fe8f3f2
take advantage of ability to intern str slices
nikomatsakis Nov 2, 2024
612a3ac
create transitive bound iterator and use that
nikomatsakis Nov 2, 2024
99a542b
rename from `SymInferVarIndex` to `InferVarIndex`
nikomatsakis Nov 2, 2024
f2c0899
subtyping work
nikomatsakis Nov 2, 2024
214caff
stop expecting dead code etc
nikomatsakis Nov 2, 2024
c815dc2
track expectations
nikomatsakis Nov 2, 2024
af375fa
thread expected, found for better errors
nikomatsakis Nov 2, 2024
921e238
add embed crate for future use
nikomatsakis Nov 2, 2024
caa8914
stop manipulating paths in the core dada logic
nikomatsakis Nov 2, 2024
4dde93e
embed libdada the fancy way
nikomatsakis Nov 2, 2024
34f9fe4
remove primitive str and use String from libdada
nikomatsakis Nov 3, 2024
befc776
only create a single SymModule for a given AST
nikomatsakis Nov 3, 2024
c3ed7cd
extract diagnostic rendering to dada-ir-ast
nikomatsakis Nov 4, 2024
ff87d03
extract dada-compiler/db into its own crate
nikomatsakis Nov 4, 2024
d3270f5
rework to be suitable for an LSP
nikomatsakis Nov 8, 2024
f7db888
use urls internally, give VFS rendering control
nikomatsakis Nov 9, 2024
95b4ec7
wip: try creating a new workspace
nikomatsakis Nov 10, 2024
41a2215
ignore vscode-test
nikomatsakis Nov 10, 2024
ef272cd
delete stuff
nikomatsakis Nov 10, 2024
2bf1c46
switch to a raw dockerfile
nikomatsakis Nov 11, 2024
8604aaa
create a vscode extension
nikomatsakis Nov 11, 2024
13ed780
iterating towards wasm-based extension
nikomatsakis Nov 11, 2024
45645ab
checkpoint
nikomatsakis Nov 12, 2024
f19fd16
give up on wasm for now
nikomatsakis Nov 12, 2024
30c2aeb
fix some things...kind of?
nikomatsakis Nov 12, 2024
40d87ef
move to our own LSP server impl
nikomatsakis Nov 15, 2024
541ffa7
pass Editor as a parameter vs to new
nikomatsakis Nov 15, 2024
af4a322
publish diagnostics
nikomatsakis Nov 16, 2024
ec2aded
integrate wasm experimentally
nikomatsakis Nov 16, 2024
896d152
upgrade wasm vscode library
nikomatsakis Nov 18, 2024
229c720
define next spike target, fix assertion failure
nikomatsakis Nov 18, 2024
817bfa5
remove pub to simplify first spike
nikomatsakis Nov 19, 2024
af55ed5
generalize class declarations to other aggregates
nikomatsakis Nov 19, 2024
640cf07
fix parsing of self
nikomatsakis Nov 19, 2024
e51f676
parse bank account example successfully
nikomatsakis Nov 19, 2024
1f7bb58
populate with permissions from leased
nikomatsakis Nov 19, 2024
5b70e62
introduce unary operator for negate
nikomatsakis Nov 19, 2024
53d0908
parse if-else-if chains
nikomatsakis Nov 19, 2024
f2502c0
parse `&&` and `||`
nikomatsakis Nov 19, 2024
6709da2
support comparison operators
nikomatsakis Nov 20, 2024
15ecb30
parse `let mut`
nikomatsakis Nov 20, 2024
ff70f49
add share/lease/give ops
nikomatsakis Nov 20, 2024
3394b4f
handle joining spans with distinct anchors
nikomatsakis Nov 20, 2024
d7cd427
handle self-argument in method calls
nikomatsakis Nov 20, 2024
89d2a3a
parse assignment
nikomatsakis Nov 20, 2024
a3a3a79
fix parsing of operators
nikomatsakis Nov 20, 2024
115098e
checkpoint for wasm-codegen
nikomatsakis Nov 24, 2024
528a750
enable ssh-agent forwarding in my Dockerfile
nikomatsakis Nov 30, 2024
f350c35
introduce `ObjectPerm`
nikomatsakis Nov 30, 2024
f24d96a
give up with ssh-agent, too annoying
nikomatsakis Dec 3, 2024
e2ff119
modify `to_object_ir` to take environment
nikomatsakis Dec 4, 2024
fab7c07
WIP checkpoint: merging check + sym
nikomatsakis Dec 8, 2024
592d4a7
WIP checkpoint
nikomatsakis Dec 8, 2024
7cd31fd
checkpoint
nikomatsakis Dec 8, 2024
516d9fc
start creating an ir submodule
nikomatsakis Dec 10, 2024
4ddc448
rename ObjectExpr to SymExpr
nikomatsakis Dec 10, 2024
0c4172f
get downstream code compiling (if not working)
nikomatsakis Dec 10, 2024
ccbd333
move object_ir into an ir submodule
nikomatsakis Dec 10, 2024
eab1733
rename ir::object_ir to ir::exprs
nikomatsakis Dec 10, 2024
70451ce
move ty to the ir submodule
nikomatsakis Dec 10, 2024
d838d9f
rename ir::ty to ir::types
nikomatsakis Dec 10, 2024
9b87a4f
move symbol to ir::symbol
nikomatsakis Dec 10, 2024
efd1ab9
move SymGenericKind to ir::types
nikomatsakis Dec 10, 2024
242b4ba
move subst to ir
nikomatsakis Dec 10, 2024
3a0d939
move primitive to ir
nikomatsakis Dec 10, 2024
cfbe6de
move function to ir
nikomatsakis Dec 10, 2024
52b8e91
rename function to functions
nikomatsakis Dec 10, 2024
da63e91
rename symbol to variables
nikomatsakis Dec 10, 2024
18d631e
indices -> ir::indices
nikomatsakis Dec 12, 2024
5711fa9
class -> ir::class
nikomatsakis Dec 12, 2024
b406a3b
ir::class -> ir::classes
nikomatsakis Dec 12, 2024
46ef26d
module -> ir::module
nikomatsakis Dec 12, 2024
433be4e
make scope private
nikomatsakis Dec 12, 2024
f393b1c
check -> runtime
nikomatsakis Dec 12, 2024
6879823
create check crate
nikomatsakis Dec 12, 2024
4aaceae
scope, scope_tree -> check
nikomatsakis Dec 12, 2024
7077f53
exprs -> check
nikomatsakis Dec 12, 2024
0f51681
populate -> check
nikomatsakis Dec 12, 2024
cbf7d45
types -> check
nikomatsakis Dec 12, 2024
cbe3487
{env, inference, runtime, universe} -> check
nikomatsakis Dec 12, 2024
b449a9e
remaining modules -> check
nikomatsakis Dec 12, 2024
ce438cb
temporaries code -> check
nikomatsakis Dec 12, 2024
30ae5f8
temporaries code -> check
nikomatsakis Dec 12, 2024
1e25249
misc_tys -> fields
nikomatsakis Dec 12, 2024
c9c6ac8
make env, env-like private to check
nikomatsakis Dec 12, 2024
27609e2
make inference private to check
nikomatsakis Dec 12, 2024
a234603
populate -> ir
nikomatsakis Dec 12, 2024
0bb30cc
add some comments
nikomatsakis Dec 12, 2024
7e001fc
member -> member_lookup
nikomatsakis Dec 12, 2024
5ed5055
cleanup some lints
nikomatsakis Dec 12, 2024
1da26f0
fill in some 'todo' items
nikomatsakis Dec 12, 2024
edcc8b6
kill some warnings
nikomatsakis Dec 12, 2024
8705806
handle short-circuiting boolean logic
nikomatsakis Dec 12, 2024
c4ceb5b
handle simple cases of checking permissions
nikomatsakis Dec 13, 2024
8968ee7
change CheckInEnv to be async
nikomatsakis Dec 13, 2024
4a1c1e0
rename CheckInEnv to CheckInEnvLike
nikomatsakis Dec 14, 2024
f1d7e2f
match method names/trait names
nikomatsakis Dec 14, 2024
b96e374
string expressions
nikomatsakis Dec 14, 2024
4b71cf1
rework prelude error reporting
nikomatsakis Dec 14, 2024
0bb661d
parse unsafe on functions
nikomatsakis Dec 15, 2024
78b4ef0
introduce a simple logging system
nikomatsakis Dec 15, 2024
d1e7308
add some basic logging infrastructure
nikomatsakis Dec 15, 2024
789ff75
log some salsa events
nikomatsakis Dec 16, 2024
8451686
make salsa logging conditional on being enabled
nikomatsakis Dec 16, 2024
07e1b39
account for inference variables found in perms
nikomatsakis Dec 17, 2024
761304a
remove protoenv
nikomatsakis Dec 18, 2024
c67f160
remove GlobalEnv
nikomatsakis Dec 19, 2024
ea4eb71
remove EnvLike trait
nikomatsakis Dec 19, 2024
e01822d
remove CheckInEnvLike trait
nikomatsakis Dec 19, 2024
18720e2
convert shared, leased permissions
nikomatsakis Dec 19, 2024
7fc9fa7
create the run command and sketch how it works
nikomatsakis Dec 20, 2024
f1f408c
extract FnIndex creation from wasm repr
nikomatsakis Dec 20, 2024
2f5071c
create a WasmReprCx
nikomatsakis Dec 20, 2024
de943f4
expand WasmReprCx to support permissions
nikomatsakis Dec 20, 2024
53684c6
kill SymPermKind::Given
nikomatsakis Dec 20, 2024
6f6bf33
move inference var modules to ir
nikomatsakis Dec 21, 2024
b144ebf
Revert "move inference var modules to ir"
nikomatsakis Dec 22, 2024
7ac35bd
checkpoint
nikomatsakis Dec 30, 2024
022051f
checkpoint
nikomatsakis Jan 3, 2025
c9968af
checkpoint
nikomatsakis Jan 4, 2025
1dc3b64
checkpoint
nikomatsakis Jan 4, 2025
d910381
checkpoint: introduce substitution impls for exprs
nikomatsakis Jan 6, 2025
bf566f2
checkpoint: introducing resolution
nikomatsakis Jan 6, 2025
7fb61e6
checkpoint: switch from subst to custom trait
nikomatsakis Jan 7, 2025
4dd6cb9
checkpoint: remove variance from resolution
nikomatsakis Jan 8, 2025
d635ea0
Revert "checkpoint: switch from subst to custom trait"
nikomatsakis Jan 8, 2025
8367f0c
checkpoint: cleanup, document, handle variance
nikomatsakis Jan 8, 2025
25a9ed8
add new keywords based on my latest design
nikomatsakis Jan 14, 2025
9d24ac9
WIP
nikomatsakis Jan 14, 2025
e83f9e4
cleanup most of subtyping implementation
nikomatsakis Jan 19, 2025
4ddfc7a
implement `is_generic` function
nikomatsakis Jan 19, 2025
320aa7e
move variance around
nikomatsakis Jan 19, 2025
a1dd3a1
adapt `async-recursion` crate, cleanup Cargo.toml
nikomatsakis Jan 20, 2025
1ec3a8f
fix handling of lifetimes in async-recursion crate
nikomatsakis Jan 20, 2025
6ce95a2
use async-fn more to see if it helps the hang
nikomatsakis Jan 20, 2025
7c876d9
Revert "use async-fn more to see if it helps the hang"
nikomatsakis Jan 20, 2025
1b1574d
comments and renames
nikomatsakis Jan 21, 2025
8c72252
comment
nikomatsakis Jan 22, 2025
5670efc
define red terms
nikomatsakis Feb 1, 2025
5f31e7b
wip: I was doing something...
nikomatsakis Feb 6, 2025
de538a5
work on proving is/isn't
nikomatsakis Feb 8, 2025
a72331c
checkpoint
nikomatsakis Feb 16, 2025
5656974
checkpoint
nikomatsakis Feb 19, 2025
a5a9474
checkpoint
nikomatsakis Feb 21, 2025
1b277f8
checkpoint
nikomatsakis Feb 23, 2025
a2c3baf
checkpoint
nikomatsakis Feb 23, 2025
cbe982a
checkpoint
nikomatsakis Feb 23, 2025
170d7d0
checkpoint
nikomatsakis Feb 23, 2025
51ebf95
checkpoint
nikomatsakis Feb 24, 2025
d3a3f96
checkpoint
nikomatsakis Feb 25, 2025
17d292b
better comments
nikomatsakis Feb 25, 2025
4355cc0
checkpoint
nikomatsakis Feb 26, 2025
e6d7193
checkpoint
nikomatsakis Feb 26, 2025
49ddca3
checkpoint
nikomatsakis Feb 27, 2025
7c28626
checkpoint
nikomatsakis Feb 28, 2025
447b37c
checkpoint
nikomatsakis Feb 28, 2025
ea657be
checkpoint
nikomatsakis Mar 2, 2025
cc52c18
checkpoint
nikomatsakis Mar 3, 2025
cd1ea7d
checkpoint
nikomatsakis Mar 3, 2025
69c477a
checkpoint
nikomatsakis Mar 4, 2025
38f094c
checkpoint
nikomatsakis Mar 4, 2025
2836708
checkpoint
nikomatsakis Mar 4, 2025
60438a5
checkpoint
nikomatsakis Mar 4, 2025
da931d6
checkpoint
nikomatsakis Mar 5, 2025
30ec4f7
checkpoint
nikomatsakis Mar 5, 2025
a697900
checkpoint
nikomatsakis Mar 5, 2025
6d70992
checkpoint
nikomatsakis Mar 6, 2025
7b2cdc3
checkpoint
nikomatsakis Mar 6, 2025
5b5e588
checkpoint
nikomatsakis Mar 6, 2025
0f7c093
checkpoint
nikomatsakis Mar 6, 2025
8ba76a1
checkpoint
nikomatsakis Mar 6, 2025
fdbe702
checkpoint
nikomatsakis Mar 6, 2025
73c57e9
checkpoint
nikomatsakis Mar 7, 2025
59f0b5b
checkpoint
nikomatsakis Mar 7, 2025
3d3dd5d
trait-upcasting is stable!
nikomatsakis Mar 7, 2025
14f8e20
checkpoint
nikomatsakis Mar 7, 2025
d09d4b4
checkpoint
nikomatsakis Mar 7, 2025
7c13abd
checkpoint
nikomatsakis Mar 7, 2025
117a600
checkpoint
nikomatsakis Mar 7, 2025
f8c6edf
comment
nikomatsakis Mar 7, 2025
13b8973
add a verbose option for running tests
nikomatsakis Mar 7, 2025
5d57465
checkpoint
nikomatsakis Mar 7, 2025
ffc901c
checkpoint
nikomatsakis Mar 7, 2025
94443b9
default to verbose with one file argument
nikomatsakis Mar 7, 2025
1870238
checkpoint
nikomatsakis Mar 7, 2025
9a6f005
add comment
nikomatsakis Mar 7, 2025
4c3ddc6
remove "cleanup" fn from `Runtime::exec`
nikomatsakis Mar 8, 2025
dc722e2
wip: start making some parts of red terms public
nikomatsakis Mar 8, 2025
a42c152
plumb inference variable values
nikomatsakis Mar 8, 2025
1ba5d28
separate codegen from diagnostics
nikomatsakis Mar 8, 2025
9446c2d
remove panic and use red-infers
nikomatsakis Mar 8, 2025
abc6b39
introduce an erased place
nikomatsakis Mar 8, 2025
b860542
cleanup and clarify bounds a bit
nikomatsakis Mar 8, 2025
b9b199e
reintroduce "resolve" to remove inference vars
nikomatsakis Mar 8, 2025
8ce59d4
move `red` to private interface
nikomatsakis Mar 8, 2025
e904696
cleanup
nikomatsakis Mar 8, 2025
485bec9
assumptions into arc
nikomatsakis Mar 8, 2025
5d7c87c
pass `&mut Env` and move combinators to methods
nikomatsakis Mar 8, 2025
699c3e9
use erased place
nikomatsakis Mar 8, 2025
2e10b72
introduce debug log
nikomatsakis Mar 10, 2025
2679f47
checkpoint
nikomatsakis Mar 10, 2025
76704f4
checkpoint
nikomatsakis Mar 11, 2025
8c404b3
dump json debugging files
nikomatsakis Mar 11, 2025
bfa4d29
use handlebars to render debug
nikomatsakis Mar 11, 2025
a26bf51
extract handlebars logic and server to a separate crate
nikomatsakis Mar 12, 2025
1ff96d0
update
nikomatsakis Mar 12, 2025
efa25f8
iterating towards debugserver
nikomatsakis Mar 13, 2025
55d9f74
checkpoint
nikomatsakis Mar 14, 2025
3f8c55e
tolerable debug log
nikomatsakis Mar 14, 2025
b2d9443
tolerable debug log
nikomatsakis Mar 14, 2025
3bdc38e
checkpoint
nikomatsakis Mar 14, 2025
3cfaf49
integrate serde, jsontree
nikomatsakis Mar 15, 2025
9e01c98
improve debug output
nikomatsakis Mar 15, 2025
ce9b6b0
test
nikomatsakis Mar 16, 2025
575c6d0
include task info
nikomatsakis Mar 16, 2025
f929b2e
pare back the book
nikomatsakis Mar 17, 2025
9ff26e7
try to fix preview
nikomatsakis Mar 17, 2025
c83bce8
improve debugging output
nikomatsakis Mar 17, 2025
78e374a
pacify the merciless clippy
nikomatsakis Mar 17, 2025
9bf2192
run cargo fmt
nikomatsakis Mar 17, 2025
1358be5
fix typos
nikomatsakis Mar 17, 2025
6ff580d
no vscode mode right now
nikomatsakis Mar 17, 2025
3efc82d
run prettier
nikomatsakis Mar 17, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[alias]
xtask = "run --package xtask --"
xtask = "run -q --package xtask --"
dada = "run -q --package dada --"
22 changes: 22 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Use the Debian base image
FROM mcr.microsoft.com/devcontainers/base:bookworm

# Install Node.js
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash - \
&& apt-get install -y nodejs

# Install additional tools or dependencies if needed
RUN npm install -g yo generator-code

# Install OpenSSH client
RUN apt-get update && apt-get install -y openssh-client

USER vscode

# Install Rust and the wasm32-wasip1-threads target
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
ENV PATH="/home/vscode/.cargo/bin:${PATH}"
RUN rustup install nightly-2025-03-01
RUN rustup target add wasm32-wasip1-threads


41 changes: 41 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/debian
{
"name": "Debian",
"build": {
"dockerfile": "Dockerfile"
},
"customizations": {
"vscode": {
"extensions": [
"ms-vscode.wasm-wasi-core",
"dbaeumer.vscode-eslint",
"ms-vscode.extension-test-runner",
"rust-lang.rust-analyzer",
// for editing Dockerfile
"ms-azuretools.vscode-docker",
// for browsing tet reports
"iliazeus.vscode-ansi",
// this is Niko's personal preference, is there a way to factor it out?
"kahole.magit"
]
}
},
"mounts": [
"source=${localEnv:HOME}/.ssh,target=/home/vscode/.ssh,type=bind"
]
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
//"image": "mcr.microsoft.com/devcontainers/base:bookworm",
//"features": {
// "ghcr.io/devcontainers/features/node:1": {},
// "ghcr.io/devcontainers/features/rust:1": {},
// "devwasm.azurecr.io/dev-wasm/dev-wasm-feature/rust-wasi:0": {}
//}
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
// Configure tool-specific properties.
// "customizations": {},
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}
27 changes: 0 additions & 27 deletions .github/workflows/editors.yml

This file was deleted.

2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
target
.vscode
playground
dada_debug

# Internal IR files used for debugging
syntax.debug
validated.debug
bir.debug
lsp.debug
dada_debug.*
15 changes: 12 additions & 3 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [

{
"type": "lldb",
"request": "launch",
"name": "Debug executable 'dada' on hello-world",
"name": "Debug executable 'dada' on a test",
"cargo": {
"args": [
"build",
Expand All @@ -20,8 +21,8 @@
}
},
"args": [
"check",
"dada_tests/hello_world.dada"
"compile",
"${input:enterProgram}"
],
"cwd": "${workspaceFolder}"
},
Expand All @@ -46,5 +47,13 @@
"__DADA_LSP_SERVER_DEBUG": "${workspaceFolder}/target/debug/dada"
}
},
],
"inputs": [
{
"id": "enterProgram",
"type": "promptString",
"description": "Program to compile",
"default": "tests/"
}
]
}
Loading
Loading