Skip to content

Commit

Permalink
More fluent GraphTraversal API (#49028)
Browse files Browse the repository at this point in the history
See vercel/turborepo#4598

### Turbopack changes

* vercel/turborepo#4754 <!-- Justin Ridgewell -
Match TS's extends resolution algorithm -->
* vercel/turborepo#4598 <!-- Alex Kirszenberg - More
fluent GraphTraversal API -->

---------

Co-authored-by: Tobias Koppers <tobias.koppers@googlemail.com>
  • Loading branch information
alexkirsz and sokra authored May 1, 2023
1 parent 7e0a6f8 commit 3362851
Show file tree
Hide file tree
Showing 5 changed files with 55 additions and 57 deletions.
66 changes: 33 additions & 33 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@ swc_relay = { version = "0.2.7" }
testing = { version = "0.33.6" }

# Turbo crates
turbo-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230501.1" }
turbo-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230501.2" }
# [TODO]: need to refactor embed_directory! macro usages, as well as resolving turbo_tasks::function, macros..
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230501.1" }
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230501.2" }
# [TODO]: need to refactor embed_directory! macro usage in next-core
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230501.1" }
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-230501.2" }

# General Deps

Expand Down
4 changes: 2 additions & 2 deletions packages/next-swc/crates/next-core/js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
"check": "tsc --noEmit"
},
"dependencies": {
"@vercel/turbopack-dev": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-dev/js?turbopack-230501.1",
"@vercel/turbopack-node": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-node/js?turbopack-230501.1",
"@vercel/turbopack-dev": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-dev/js?turbopack-230501.2",
"@vercel/turbopack-node": "https://gitpkg.vercel.app/vercel/turbo/crates/turbopack-node/js?turbopack-230501.2",
"anser": "^2.1.1",
"css.escape": "^1.5.1",
"next": "*",
Expand Down
18 changes: 8 additions & 10 deletions packages/next-swc/crates/next-core/src/manifest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,16 +67,14 @@ impl DevManifestContentSourceVc {
Ok(content_source.get_children().await?.clone_value())
}

let routes = GraphTraversal::<NonDeterministic<_>>::visit(
this.page_roots.iter().copied(),
get_content_source_children,
)
.await
.completed()?
.into_iter()
.map(content_source_to_pathname)
.try_join()
.await?;
let routes = NonDeterministic::new()
.visit(this.page_roots.iter().copied(), get_content_source_children)
.await
.completed()?
.into_iter()
.map(content_source_to_pathname)
.try_join()
.await?;
let mut routes = routes
.into_iter()
.flatten()
Expand Down
18 changes: 9 additions & 9 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3362851

Please sign in to comment.