Skip to content
This repository was archived by the owner on Jul 3, 2023. It is now read-only.

Commit f8bf049

Browse files
committed
Go back to stable Rust.
The Generic Associated Types (GAT) feature of Rust is now stable since 1.65, so we no longer need to rely on nightly Rust.
1 parent 9f1b8f1 commit f8bf049

File tree

6 files changed

+23
-22
lines changed

6 files changed

+23
-22
lines changed

.github/workflows/bench.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ jobs:
4444
uses: actions-rs/toolchain@v1
4545
with:
4646
profile: minimal
47-
toolchain: nightly
47+
toolchain: stable
4848
default: true
4949

5050
- name: Restore cache

.github/workflows/coverage.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
uses: actions-rs/toolchain@v1
3737
with:
3838
profile: minimal
39-
toolchain: nightly
39+
toolchain: stable
4040
components: llvm-tools-preview
4141
override: true
4242

.github/workflows/main.yml

+18-16
Original file line numberDiff line numberDiff line change
@@ -38,32 +38,31 @@ jobs:
3838

3939
matrix:
4040
# We test the following targets:
41-
# - 64bit Linux nightly
41+
# - 64bit Linux stable
4242
# - 64bit Linux beta
4343
# - 64bit Linux nightly
44-
# - 64bit MacOS nightly
45-
# - 64bit Windows nightly
46-
# - 32bit Windows nightly
44+
# - 64bit MacOS stable
45+
# - 64bit Windows stable
46+
# - 32bit Windows stable
4747
include:
4848
- {
49-
rust: nightly,
49+
rust: stable,
5050
target: x86_64-unknown-linux-gnu,
5151
os: [self-hosted, Linux, skylake-2x],
5252
}
53-
- { rust: nightly, target: x86_64-apple-darwin, os: macos-latest }
53+
- { rust: stable, target: x86_64-apple-darwin, os: macos-latest }
5454
- {
55-
rust: nightly,
55+
rust: stable,
5656
target: x86_64-pc-windows-msvc,
5757
os: windows-latest,
5858
}
59-
- { rust: nightly, target: i686-pc-windows-msvc, os: windows-latest }
60-
# TODO: uncomment when we're back to stable Rust.
61-
#- { rust: beta, target: x86_64-unknown-linux-gnu, os: ubuntu-latest }
62-
#- {
63-
# rust: nightly,
64-
# target: x86_64-unknown-linux-gnu,
65-
# os: ubuntu-latest,
66-
#}
59+
- { rust: stable, target: i686-pc-windows-msvc, os: windows-latest }
60+
- { rust: beta, target: x86_64-unknown-linux-gnu, os: ubuntu-latest }
61+
- {
62+
rust: nightly,
63+
target: x86_64-unknown-linux-gnu,
64+
os: ubuntu-latest,
65+
}
6766

6867
steps:
6968
- name: Checkout
@@ -234,6 +233,7 @@ jobs:
234233
uses: actions-rs/toolchain@v1
235234
with:
236235
profile: minimal
236+
# Run nightly clippy, which often finds additional issues.
237237
toolchain: nightly
238238
components: clippy
239239
default: true
@@ -261,6 +261,8 @@ jobs:
261261
uses: actions-rs/toolchain@v1
262262
with:
263263
profile: minimal
264+
# We use unstable rustfmt features: `wrap_comments` and
265+
# `format_code_in_doc_comments`.
264266
toolchain: nightly
265267
components: rustfmt
266268
default: true
@@ -285,7 +287,7 @@ jobs:
285287
uses: actions-rs/toolchain@v1
286288
with:
287289
profile: minimal
288-
toolchain: nightly
290+
toolchain: stable
289291
default: true
290292

291293
- name: Restore cache

adapters/src/controller/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -442,7 +442,7 @@ impl ControllerInner {
442442
let parser = format.new_parser(&endpoint_config.format.config, &self.catalog)?;
443443

444444
// Create probe.
445-
let endpoint_id = inputs.last_key_value().map(|(k, _)| k + 1).unwrap_or(0);
445+
let endpoint_id = inputs.iter().rev().next().map(|(k, _)| k + 1).unwrap_or(0);
446446
let probe = Box::new(InputProbe::new(
447447
endpoint_id,
448448
endpoint_name,

rust-toolchain.toml

-2
This file was deleted.

tools/pre-push

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ echo "Checking Rust rules prior to push. To run this check by hand invoke 'tool
77

88
set -ex
99

10-
cargo fmt --all -- --check
10+
# We use unstable `rustfmt` features: `wrap_comments` and `format_code_in_doc_comments`
11+
RUSTUP_TOOLCHAIN=nightly cargo fmt --all -- --check
1112
cargo clippy --workspace -- -D warnings
1213

1314
RUSTDOCFLAGS="-Dwarnings" cargo doc --workspace

0 commit comments

Comments
 (0)