From e995ec37b5a47493c4b16113e7dd0effd60ea74b Mon Sep 17 00:00:00 2001 From: figsoda Date: Tue, 11 Apr 2023 13:35:57 -0400 Subject: [PATCH] rustc: reapply re-erased-regions-are-local patch The patch is not in 1.68, and was mistakenly removed --- pkgs/development/compilers/rust/1_68.nix | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/pkgs/development/compilers/rust/1_68.nix b/pkgs/development/compilers/rust/1_68.nix index d691a30c51b5ff..54c9c4a9f1ad0b 100644 --- a/pkgs/development/compilers/rust/1_68.nix +++ b/pkgs/development/compilers/rust/1_68.nix @@ -17,6 +17,7 @@ , makeRustPlatform , llvmPackages_11 , llvmPackages_15, llvm_15 +, fetchpatch } @ args: import ./default.nix { @@ -57,7 +58,16 @@ import ./default.nix { selectRustPackage = pkgs: pkgs.rust_1_68; - rustcPatches = [ ]; + rustcPatches = [ + # Fixes ICE. + # https://github.com/rust-lang/rust/pull/107688 + (fetchpatch { + name = "re-erased-regions-are-local.patch"; + url = "https://github.com/rust-lang/rust/commit/9d110847ab7f6aef56a8cd20cb6cea4fbcc51cd9.patch"; + excludes = [ "*tests/*" ]; + hash = "sha256-EZH5K1BEOOfi97xZr1xEHFP4jjvJ1+xqtRMvxBoL8pU="; + }) + ]; } -(builtins.removeAttrs args [ "pkgsBuildHost" "llvmPackages_11" "llvmPackages_15" "llvm_15"]) +(builtins.removeAttrs args [ "fetchpatch" "pkgsBuildHost" "llvmPackages_11" "llvmPackages_15" "llvm_15"])