Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pre-expansion gate (almost) all the things #64672

Open
wants to merge 16 commits into
base: master
from

Conversation

@Centril
Copy link
Member

commented Sep 21, 2019

Move feature gating of various unstable syntactic features to the parser.

Also fix a bug in trait aliases (trait Foo: Bar = Baz; parsed contrary to RFC and had no effect).

r? @petrochenkov

@Centril

This comment was marked as resolved.

Copy link
Member Author

commented Sep 21, 2019

Oops; forgot to add a test for the trait alias thingy, will do in a bit.

if self.eat(&token::Eq) {
// It's a trait alias.
if span_at_colon != span_before_eq {

This comment has been minimized.

Copy link
@petrochenkov

petrochenkov Sep 22, 2019

Contributor
Suggested change
if span_at_colon != span_before_eq {
if had_colon {

?

Spans are unreliable and can all be dummy easily, parser shouldn't generally rely on them.

Also, if this is a syntactic error (as opposed to a semantic error), then empty bound list trait Alias: /* nothing */ = Bounds; should also be an error.

This comment has been minimized.

Copy link
@Centril

Centril Sep 22, 2019

Author Member

Ah, wasn't sure about the approach I was using, so it's great you pointed it out, thanks. Will fix. :)

@petrochenkov

This comment has been minimized.

Copy link
Contributor

commented Sep 22, 2019

Implementation looks good, but this needs a crater run, and then perhaps some soft feature-gating depending on its result.

@bors try

@bors

This comment has been minimized.

Copy link
Contributor

commented Sep 22, 2019

⌛️ Trying commit 18a29c6 with merge 00e4530...

bors added a commit that referenced this pull request Sep 22, 2019
Pre-expansion gate (almost) all the things

Move feature gating of various unstable syntactic features to the parser.

Also fix a bug in trait aliases (`trait Foo: Bar = Baz;` parsed contrary to RFC and had no effect).

r? @petrochenkov
@bors

This comment has been minimized.

Copy link
Contributor

commented Sep 22, 2019

☀️ Try build successful - checks-azure
Build commit: 00e4530

@Centril

This comment has been minimized.

Copy link
Member Author

commented Sep 22, 2019

@craterbot run mode=check-only

@craterbot

This comment has been minimized.

Copy link
Collaborator

commented Sep 22, 2019

👌 Experiment pr-64672 created and queued.
🤖 Automatically detected try build 00e4530
🔍 You can check out the queue and this experiment's details.

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot

This comment has been minimized.

Copy link
Collaborator

commented Oct 10, 2019

🚧 Experiment pr-64672 is now running

ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@craterbot

This comment has been minimized.

Copy link
Collaborator

commented Oct 14, 2019

🎉 Experiment pr-64672 is completed!
📊 322 regressed and 0 fixed (74234 total)
📰 Open the full report.

⚠️ If you notice any spurious failure please add them to the blacklist!
ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more

@petrochenkov

This comment has been minimized.

Copy link
Contributor

commented Oct 14, 2019

Marking as waiting on author to triage the regressions.

@Centril

This comment has been minimized.

Copy link
Member Author

commented Oct 16, 2019

crates.io

error[E0658]: try blocks are unstable

Number of crates regressed: 1

  • try-guard-0.2.0 (Centril's note: it is a test)

error[E0658]: auto traits are experimental and possibly buggy

Number of crates regressed: 17

  • airmash-protocol-0.3.0

  • bigqueue-0.0.2

  • dimensioned-0.7.0

  • doh-client-1.4.4

  • emseries-0.4.0

  • git_rs-0.1.0

  • lru-0.1.17

  • mft-0.4.4

  • nonogrid-0.5.2

  • rqrr-0.2.0

  • signalo_sinks-0.5.1

  • signalo_sources-0.5.1

  • sortuniq-0.1.0

  • tox-0.0.10

  • tox-node-0.0.8

  • webauthn-rs-0.1.4

  • xfetch-0.1.0

error[E0658]: extern types are experimental

Number of crates regressed: 98

  • angular-rs-0.1.0

  • awsm-0.0.11

  • awsm_web-0.0.6

  • azure_sdk_auth_aad-0.21.0

  • blockchain-network-simple-0.5.0

  • blurhash-wasm-0.2.0

  • breakout-wasm-0.2.2

  • cargo-geiger-0.7.3

  • cargo-tarpaulin-0.8.6

  • console-web-0.1.2

  • console_log-0.1.2

  • cratchit-0.0.4

  • document-ready-1.0.1

  • dodrio-0.1.0

  • dodrio-js-api-0.1.0

  • draco-0.1.2

  • electron-sys-0.1.0

  • futures_ringbuf-0.1.2

  • glium-0.26.0-alpha3

  • graphql_client_web-0.8.0

  • https-everywhere-lib-wasm-0.1.2

  • impulse-0.1.1

  • indexeddb-0.1.0

  • infuse-0.4.0

  • js-intern-0.3.1

  • js-intern-core-0.3.1

  • js-object-0.2.0

  • js-sys-0.3.27

  • libp2p-0.12.0

  • libp2p-wasm-ext-0.5.0

  • mech-wasm-0.0.2

  • medea-jason-0.1.0

  • meowj-0.2.0

  • mice-0.4.0

  • mika-0.0.0

  • mop-bindings-0.0.8

  • moxie-web-0.1.0

  • n5-wasm-0.1.0

  • node-sys-0.1.0

  • ojo_wasm-0.1.0

  • oxygengine-backend-web-0.4.4

  • oxygengine-composite-renderer-backend-web-0.4.4

  • oxygengine-input-device-web-0.4.4

  • oxygengine-network-backend-web-0.4.4

  • percy-webapis-0.0.2

  • piet-web-0.0.6

  • pir-8-emu-0.1.1

  • plaster-0.2.5

  • plaster-forms-0.1.16

  • plaster-router-0.1.5

  • plaster-router-macro-0.1.1

  • prototty_wasm-0.27.0

  • prototty_wasm_render-0.27.0

  • prototty_wasm_storage-0.27.0

  • qjs-0.1.2

  • quilt_wasm-0.1.1

  • router-rs-0.2.1

  • router-xiaobei-0.1.2

  • rusty_ulid-0.9.1

  • ruukh-0.0.3

  • saphir-0.9.4

  • sauron-native-0.1.0

  • seed-0.4.0

  • serde-wasm-bindgen-0.1.3

  • simi-0.2.1

  • simi-test-0.1.0

  • smd_macro-0.0.7

  • smd_tests-0.0.7

  • smithy-0.0.7

  • smithy_core-0.0.7

  • smithy_types-0.0.7

  • spherro-0.2.1

  • squark-web-0.3.0

  • ss-dom-tree-0.1.1

  • ss-trees-0.1.1

  • ss-view-tree-0.1.1

  • ss-web-utils-0.1.1

  • subscript-0.2.9

  • tera-1.0.0-beta.14

  • typed-array-0.2.0

  • virtual-dom-rs-0.6.10

  • virtual-node-0.2.6

  • vscode-sys-0.1.0

  • wasm-bindgen-0.2.50

  • wasm-bindgen-futures-0.3.27

  • wasm-bindgen-test-0.2.50

  • wasm-logger-0.1.5

  • wasm-stopwatch-0.1.0

  • web-console-logger-0.1.2

  • web-sys-0.3.27

  • web_worker-0.1.0

  • webblender-0.1.1

  • webgl-rs-0.2.2

  • ws_stream_wasm-0.2.1

  • wurst-0.2.0

  • yoloxide-0.4.3

  • yt-tools-0.3.0

  • zs-filecrawler-0.0.3

error[E0658]: negative trait bounds are not yet fully implemented; use marker types for now

Number of crates regressed: 30

  • airmash-protocol-0.3.0

  • beep-0.2.1

  • bigqueue-0.0.2

  • byteorder-pod-0.1.0

  • dimensioned-0.7.0

  • doh-client-1.4.4

  • emseries-0.4.0

  • futures-async-runtime-0.2.1

  • futures-async-runtime-preview-0.2.3

  • futures-v02x-0.1.0

  • git_rs-0.1.0

  • interprocess-traits-0.1.1

  • lru-0.1.17

  • lsm303-0.1.0

  • metric-0.1.2

  • mft-0.4.4

  • nonogrid-0.5.2

  • ocl-extras-0.1.1

  • ophir-0.2.5

  • packed-0.4.2

  • pod-0.5.0

  • rats-0.0.1

  • rqrr-0.2.0

  • signalo_sinks-0.5.1

  • signalo_sources-0.5.1

  • sortuniq-0.1.0

  • tox-0.0.10

  • tox-node-0.0.8

  • webauthn-rs-0.1.4

  • xfetch-0.1.0

error[E0658]: type ascription is experimental

Number of crates regressed: 5

  • anterofit-0.2.0 (Centril's note: seems to be in an example)

  • preftool-app-config-0.2.0

  • preftool-dirs-0.2.0 (Centril's note: this is the root regression)

  • preftool-file-0.2.0

  • preftool-toml-0.2.0

GitHub

error[E0658]: auto traits are experimental and possibly buggy

Number of crates regressed: 7

  • DpEpsilon-synthapse-rs

  • Lytigas-drive-sim

  • benfred-py-spy

  • droundy-gasbeam-paper

  • jonlamb-gh-elis-app

  • jonlamb-gh-rust-test-webapp

  • letmutx-dex-parser

error[E0658]: box expression syntax is experimental; you can call Box::new instead

Number of crates regressed: 1

  • westerhack-qutie_rust

error[E0658]: extern types are experimental

Number of crates regressed: 165

  • 367718-arisu

  • AvraamMavridis-rust-checkers

  • CL4PTP-dbapp

  • CallumJHays-wasm-bindgen-futures-test

  • ChrisWhealy-coin_sort_wasm2

  • ChrisWhealy-porous_absorber

  • Cosmian-gll-draw

  • DR-BoneZ-borker-rs

  • Grunzwanzling-genericspace

  • IOuser-rust-wasm

  • JordanJTW-RUST-8

  • JulianKniephoff-snek

  • LucianoBestia-fetchtest

  • LucianoBestia-mem1

  • LucianoBestia-mem2

  • LukasKalbertodt-psymagen

  • Madao-3-wasm-yaml

  • Mark-Simulacrum-async-fn-size

  • MaulingMonkey-rust_wasm_sample

  • Menschenkindlein-invaders

  • Michael-St-James-wasm-game-of-life

  • MoonL1ght-rust-wasm

  • NightStr-actix-calculator

  • Pauan-war-game

  • Pauan-wasm-pack-perf-test

  • QwantResearch-fafnir

  • ROki1988-ot-rs

  • Ragnaroek-libmaze

  • RainerBlessing-wasm_snake

  • Rauno56-watchman

  • SallySoul-ete

  • Schaeff-zokrates_wasm_resolver_playground

  • Schaeff-zokrates_web_prover

  • Siiiimon-eve-mirror

  • SolarOmni-RustyRogue

  • SpaceEraser-evolutionary_regression

  • SpiderOak-react-markdown-wasm

  • SpiderOak-react-wasm-bridge

  • TheOZoneBE-webgl-rs

  • ThomWright-kvs

  • ThomasdenH-pdf.js-wasm

  • TomasHubelbauer-rust-wasm

  • TradaTech-icetea-wasm

  • WAFFO-hello-wasm-webgl

  • Yuiki-bist

  • ZiCog-insane-british-anagram-rust

  • aep-carrier-custom-service-example

  • alexlapa-wasm-pack-698-reproduction

  • anderejd-electron-wasm-rust-example

  • anderejd-wasm-bindgen-minimal-example

  • anhmv-stats.rs

  • anlumo-webgl_rust_demo

  • ashtuchkin-rypt

  • augustocdias-rust-wasm-test

  • backwardspy-wasm-gol

  • baskerville-plato

  • brettcannon-python-launcher

  • bschwind-secret-santa

  • caelra-rust-wasm-demo

  • carols10cents-cargo-open

  • ceranco-life-rs

  • chengzibaba-GameOfLife

  • codeworm96-hikari

  • colbyn-view-prototype

  • craigmayhew-bigprimes.net-rust-wasm

  • craigmayhew-game-of-life

  • crome110-iiif-manga-viewer-frontend

  • davhogan-MyBuddy

  • dbrgn-airspace-visualizer

  • devetry-mustachers

  • dlgchg-wechat_rust

  • dsbrgg-rust-wasm

  • eduidl-tetris

  • eggmund-langtons_ant

  • emilk-hobogo

  • enricobn-slideshow

  • fasterthanlime-ziptest-rs

  • felipecsl-rusty-chess

  • felixzhuologist-wasm-chip8

  • finegeometer-cubic-curve

  • finegeometer-four-dimensions

  • fitzgen-dodrio-todomvc-wasm-instantiation

  • foldu-iv

  • gesterhuizen-sauron-onclick

  • gregtatum-wasm-canvas

  • h1romas4-rust-synth-emulation

  • h1romas4-wasm-canvas-bitblt

  • h3nnn4n-Rust-TypeScript-Wasm-Template

  • h3nnn4n-Strange-Attractor-Explorer

  • h3nnn4n-julia-dioxide

  • h3nnn4n-smart-panda

  • henrikvik-wasm_pong

  • hnefatl-rust-linked-lists

  • hnefatl-rust-particles

  • hughlang-fuzzy-sims

  • ibaryshnikov-rust-webgl-engine-boilerplate

  • ibaryshnikov-webgl-engine

  • ihakkitekin-rust-http-server

  • ilkomiliev-rust-game-impl

  • indutny-dumb-scrypt-wasm

  • jackharrhy-meowj

  • jawm-protolang

  • jcoglan-ray-tracer

  • jojolepro-specs_wasm

  • jptomanelli-rust-wasm-doom-fire

  • juneil-wasm-client-irc

  • kanekv-actix-async-await

  • krasnobaev-webasm-fmosc

  • laptou-yew-test

  • leegee-rust-ts-boilerplate

  • mateuszJS-battle

  • maxbla-unit-converter

  • miguelmota-rust-wasm-example

  • mizkichan-rust-canvas-example

  • mmmpa-wasm-loan-revolver

  • mtannerman-rust-server

  • nilinswap-snake_wasm

  • nishitaniyuki-wasm-hello-world

  • niveau0-ci-dashboard

  • nrayamajhee-moksha

  • nstoddard-ca-3d

  • nstoddard-webgl-gui-demo

  • pavelsavara-game-of-life

  • plaptov-ant_sim_rs

  • practical-rust-web-development-front_raw_mystore

  • pragyandas-particle-system-wasm

  • qvantor-fabric.rs

  • r-bar-seed-wasm-experiment

  • rajeevriitm-raincatcher_rust_game

  • rasviitanen-glust-kernel

  • rbalicki2-basic_futures

  • rbalicki2-rustactoe

  • rclement-life-wasm

  • richard-reece-md-toc

  • rikshot-testbed

  • rooat-front-rust

  • scampi-falcon

  • segler-alex-stream-check-rust

  • selaux-qrcode-wasm

  • sendilkumarn-draw-page

  • sendilkumarn-state-machine

  • skaggmannen-rusty-mines

  • sneakycrow-rust-api-example

  • synlestidae-webnes

  • szymonkaliski-behaviours-rs

  • tatref-chip8

  • theduke-wasm-debug-instantiate

  • threema-ch-compose-area

  • tismith-device-checkout-rs

  • tskinn-lot

  • twhiteheadzm-cube

  • txus-jam

  • ulip128-algo

  • utkarshkukreti-draco

  • utkarshkukreti-draco-starter

  • venil7-rust-minimax

  • verseatile-wasm-game-of-life

  • wakuwaku3-example-rust-wasm

  • wasmup-server-rs

  • wildthingz-game-of-life

  • wischli-rpaillier

  • xd009642-tarpaulin

  • xuu-wasm-tetris

  • yoshou-videocoreiv-sim

  • yshryk-igo-wasm-demo

error[E0658]: negative trait bounds are not yet fully implemented; use marker types for now

Number of crates regressed: 20

  • DpEpsilon-synthapse-rs

  • Jorch72-kristforge

  • Licenser-rust_ring

  • Lytigas-drive-sim

  • MeisterTea-malabar

  • NikosEfthias-rust-lessons-code

  • alanhoff-rust-example-actix

  • benfred-py-spy

  • droundy-gasbeam-paper

  • emkay-tiny-cache

  • jonlamb-gh-elis-app

  • jonlamb-gh-rust-test-webapp

  • jswrenn-beep

  • letmutx-dex-parser

  • lofim-actix-todo

  • nwoeanhinnogaehr-flow-synth

  • shockham-engine_arch

  • sourcepirate-pichu

  • tcsc-firkin

  • x1a0-bcproxy-rust

error[E0658]: type ascription is experimental

Number of crates regressed: 2

  • akky2501-Ruml

  • akky2501-mincaml-rust

@Centril

This comment has been minimized.

Copy link
Member Author

commented Oct 16, 2019

Notes:

  • The type ascription regressions in crates.io are really just 2, one of which is in an example and the rest have the same root regression and are part of the same project.

My suggestion is that we soft-gate (tho I'm not sure how to do it...) / wait with:

  • auto traits
  • negative trait impls
  • extern types

Everything else can be pre-expansion gated immediately (I will cherry-pick out a separate PR that does this.) and then we can consider the rest.

@petrochenkov

This comment has been minimized.

Copy link
Contributor

commented Oct 16, 2019

I agree with the conclusions, waiting on the PR hard-gating everything except auto traits, negative impls and extern types.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants
You can’t perform that action at this time.