Skip to content

Commit

Permalink
update turbopack (#58243)
Browse files Browse the repository at this point in the history
  • Loading branch information
sokra authored Nov 9, 2023
1 parent 51fec99 commit bf966e3
Show file tree
Hide file tree
Showing 7 changed files with 85 additions and 66 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 @@ -40,11 +40,11 @@ next-transform-strip-page-exports = { path = "packages/next-swc/crates/next-tran
testing = { version = "0.35.7" }

# Turbo crates
turbopack-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-231108.1" }
turbopack-binding = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-231109.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-231108.1" }
turbo-tasks = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-231109.2" }
# [TODO]: need to refactor embed_directory! macro usage in next-core
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-231108.1" }
turbo-tasks-fs = { git = "https://github.com/vercel/turbo.git", tag = "turbopack-231109.2" }

# General Deps

Expand Down
20 changes: 16 additions & 4 deletions packages/next-swc/crates/napi/src/next_api/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,20 +131,32 @@ impl From<&PlainIssue> for NapiIssue {
#[napi(object)]
pub struct NapiIssueSource {
pub source: NapiSource,
pub start: NapiSourcePos,
pub end: NapiSourcePos,
pub range: Option<NapiIssueSourceRange>,
}

impl From<&PlainIssueSource> for NapiIssueSource {
fn from(
PlainIssueSource {
asset: source,
start,
end,
range,
}: &PlainIssueSource,
) -> Self {
Self {
source: (&**source).into(),
range: range.as_ref().map(|range| range.into()),
}
}
}

#[napi(object)]
pub struct NapiIssueSourceRange {
pub start: NapiSourcePos,
pub end: NapiSourcePos,
}

impl From<&(SourcePos, SourcePos)> for NapiIssueSourceRange {
fn from((start, end): &(SourcePos, SourcePos)) -> Self {
Self {
start: (*start).into(),
end: (*end).into(),
}
Expand Down
2 changes: 1 addition & 1 deletion packages/next/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@
"@types/ws": "8.2.0",
"@vercel/ncc": "0.34.0",
"@vercel/nft": "0.22.6",
"@vercel/turbopack-ecmascript-runtime": "https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-231108.1",
"@vercel/turbopack-ecmascript-runtime": "https://gitpkg-fork.vercel.sh/vercel/turbo/crates/turbopack-ecmascript-runtime/js?turbopack-231109.2",
"acorn": "8.5.0",
"amphtml-validator": "1.0.35",
"anser": "1.4.9",
Expand Down
6 changes: 4 additions & 2 deletions packages/next/src/build/swc/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -485,8 +485,10 @@ export interface Issue {
ident: string
content?: string
}
start: { line: number; column: number }
end: { line: number; column: number }
range?: {
start: { line: number; column: number }
end: { line: number; column: number }
}
}
documentationLink: string
subIssues: Issue[]
Expand Down
Loading

0 comments on commit bf966e3

Please sign in to comment.