about summary refs log tree commit diff
path: root/compiler/rustc_ast/src/entry.rs
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2024-12-14 09:13:12 +0100
committerRalf Jung <post@ralfj.de>2025-01-21 06:59:15 -0700
commit56c90dc31e86bbaf486826a21a33d7c56e8f742f (patch)
tree6b953e5db742226ed1297f87196a69c1d51bd1d7 /compiler/rustc_ast/src/entry.rs
parent341f60327fa5302732a4be366949c16f91870b6a (diff)
downloadrust-56c90dc31e86bbaf486826a21a33d7c56e8f742f.tar.gz
rust-56c90dc31e86bbaf486826a21a33d7c56e8f742f.zip
remove support for the #[start] attribute
Diffstat (limited to 'compiler/rustc_ast/src/entry.rs')
-rw-r--r--compiler/rustc_ast/src/entry.rs10
1 files changed, 1 insertions, 9 deletions
diff --git a/compiler/rustc_ast/src/entry.rs b/compiler/rustc_ast/src/entry.rs
index ab1413d6080..12cbb3b2a15 100644
--- a/compiler/rustc_ast/src/entry.rs
+++ b/compiler/rustc_ast/src/entry.rs
@@ -18,12 +18,6 @@ pub enum EntryPointType {
     /// fn main() {}
     /// ```
     RustcMainAttr,
-    /// This is a function with the `#[start]` attribute.
-    /// ```ignore (clashes with test entrypoint)
-    /// #[start]
-    /// fn main() {}
-    /// ```
-    Start,
     /// This function is **not** an entrypoint but simply named `main` (not at the root).
     /// This is only used for diagnostics.
     /// ```
@@ -40,9 +34,7 @@ pub fn entry_point_type(
     at_root: bool,
     name: Option<Symbol>,
 ) -> EntryPointType {
-    if attr::contains_name(attrs, sym::start) {
-        EntryPointType::Start
-    } else if attr::contains_name(attrs, sym::rustc_main) {
+    if attr::contains_name(attrs, sym::rustc_main) {
         EntryPointType::RustcMainAttr
     } else if let Some(name) = name
         && name == sym::main