Message ID | 20240207114419.1100894-15-arthur.cohen@embecosm.com |
---|---|
State | New |
Headers | show
Return-Path: <gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=embecosm.com header.i=@embecosm.com header.a=rsa-sha256 header.s=google header.b=LwJsNX9D; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=8.43.85.97; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4TVKm949j8z23gT for <incoming@patchwork.ozlabs.org>; Wed, 7 Feb 2024 23:53:13 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 959C0385782B for <incoming@patchwork.ozlabs.org>; Wed, 7 Feb 2024 12:53:11 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-wm1-x331.google.com (mail-wm1-x331.google.com [IPv6:2a00:1450:4864:20::331]) by sourceware.org (Postfix) with ESMTPS id D152138582AE for <gcc-patches@gcc.gnu.org>; Wed, 7 Feb 2024 12:44:13 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org D152138582AE Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=embecosm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=embecosm.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org D152138582AE Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::331 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1707309862; cv=none; b=FtG3PsLSBpm71N4FPyKoU2ptAQlH4GPLTeUnrBZNepqupKmnasHVC+AqQoE+Txawf3GRKZ8gbvCZ9q4LtH1w+QHCUm38Y0VFdDA5Tlr3ls/vr0DXIpx3aW+5e1Hi/fJ5Xb8Gk0VBai6L2hB1d3HjRm655OP2/VYzDSbVY+fqKV8= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1707309862; c=relaxed/simple; bh=Y87feO7Zvpa7AUiPI0qkgfuC+NuJFL9HNIDC2zR4W4s=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=gKhgIB5ZpNlMF58h4TEDpf5mrzPZwcKTKkBWNPetM/GvcY5qM9PkNzLi96Ksc6SrBd/0RFZxhTkP3OZW/rLQQm2Y/PZP9c59F9lRAU7rS92INyl7A8B88X0yf4teW33YaSMKj4GwzqOp0qdy/U+c1b0d1DIEQFwseRahZDPNjbo= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-4101fc00832so1131685e9.3 for <gcc-patches@gcc.gnu.org>; Wed, 07 Feb 2024 04:44:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=embecosm.com; s=google; t=1707309852; x=1707914652; darn=gcc.gnu.org; h=content-transfer-encoding:mime-version:reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=QpFcSii0x7VBtidrQYPvIjRrzKOg4eZf6x+G1FDSSMg=; b=LwJsNX9DpnEgX3ppAaoIARe++YJ1TEJETgYRCbiOfymGFMea8SLhrf0OYtCQindCNR AQu4twcSnddbht4YhvzPzhxKaPoXnoRIV98ufIGt0QBQXdi601Wv4mZT55YAhKlVIvH7 CQtBhDMm9hDtEAqvw7gpSoJdK99lNdsj+xccdgID7UnzlUJm0XNJDVpk8luQqTxV1vjD 6J3lrN4xSnTm6qttyEWqx+ey99AnRXE+NZI2KLAr8S5DY219osXsN5G7QS53b7JSSmSw Hb0+0BDd7EabXBXLUnk7XOOds3NpE7c/PFLoNhQQYGV/OhglixxPufri896v726crJVl ax4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707309852; x=1707914652; h=content-transfer-encoding:mime-version:reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=QpFcSii0x7VBtidrQYPvIjRrzKOg4eZf6x+G1FDSSMg=; b=Nf94/eXYitD1771s+cTlCU9/OS2W8sxdBdbvJ1Fc97pQv+1CeLL+V22BNxJ9FKyVTS D6aNZqsRuWqBc7zyXp6cq7X3ppCe5Gu1G77n0QSmKio0srlA25q1Goe9TUfBrDUBnojT OVzyDKq+Ucaf4rlvI7+WgEky3sBrqZyA1JZ+VD+qwGKGf/TSd/YJIJ+asfdp+zPcZSa+ pV6QCa/JbEPeopTC2hhTresywKXJ/mgNdn3DMs/qcTllRSaZr0Pwf3PbYIEQu8QZnlx3 ls/jMvH3wcG7jvKO5LXxIcliZErwINli7uNuvlFSWLLWMqNbnvX7coovfqu05gpBv/LI oT5g== X-Gm-Message-State: AOJu0Yxqznpu+URVDsBsv1aKcKeC+naDSUlpdH4m2hUVqPSOx2275Ol4 MynLBlotxxSAkhb73f1Vlq06/SI6ccrmAKc149qlLbvqHBcx0cHmlc2ERGVya9o7XOIbxGKQef2 A2g== X-Google-Smtp-Source: AGHT+IGodsrZs0tEa7vh+x5pL9HzzVUJ69Yqighhd5JasGEdDbrcPs0i2DlIwooXdIIVVb2ucZ2vcA== X-Received: by 2002:a05:600c:4588:b0:40e:cdff:8d10 with SMTP id r8-20020a05600c458800b0040ecdff8d10mr4390597wmo.6.1707309852486; Wed, 07 Feb 2024 04:44:12 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCU5kHd01Wi091T0IEGgrk3IoDtmbPTzhQKqDie+5ROP3NI45xZBQKptqZwS216CDAxu+Rwwze7cfuyTkJNGln45ot4BBrj5xytJ9yFU Received: from platypus.sou.embecosm-corp.com ([212.69.42.53]) by smtp.gmail.com with ESMTPSA id x19-20020a05600c2a5300b0040fbdd6f69bsm5044188wme.33.2024.02.07.04.44.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 04:44:11 -0800 (PST) From: arthur.cohen@embecosm.com To: gcc-patches@gcc.gnu.org Cc: gcc-rust@gcc.gnu.org, Philip Herron <herron.philip@googlemail.com> Subject: [COMMITTED 14/25] gccrs: remove similar hack in type paths as we had in path expressions Date: Wed, 7 Feb 2024 12:44:00 +0100 Message-ID: <20240207114419.1100894-15-arthur.cohen@embecosm.com> X-Mailer: git-send-email 2.42.1 In-Reply-To: <20240207114419.1100894-2-arthur.cohen@embecosm.com> References: <20240207114419.1100894-2-arthur.cohen@embecosm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-13.9 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Reply-To: arthur.cohen@embecosm.com Errors-To: gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org |
Series |
[COMMITTED,01/25] gccrs: Parse normal functions with `self` parameter correctly
|
expand
|
diff --git a/gcc/rust/typecheck/rust-hir-type-check-type.cc b/gcc/rust/typecheck/rust-hir-type-check-type.cc index 0d108c3959c..74a12c4b011 100644 --- a/gcc/rust/typecheck/rust-hir-type-check-type.cc +++ b/gcc/rust/typecheck/rust-hir-type-check-type.cc @@ -572,22 +572,6 @@ TypeCheckType::resolve_segments ( } context->insert_receiver (expr_mappings.get_hirid (), prev_segment); - if (tyseg->needs_generic_substitutions ()) - { - // location_t locus = segments.back ()->get_locus (); - if (!prev_segment->needs_generic_substitutions ()) - { - auto used_args_in_prev_segment - = GetUsedSubstArgs::From (prev_segment); - if (!used_args_in_prev_segment.is_error ()) - tyseg - = SubstMapperInternal::Resolve (tyseg, used_args_in_prev_segment); - } - - if (tyseg->get_kind () == TyTy::TypeKind::ERROR) - return new TyTy::ErrorType (expr_id); - } - rust_assert (resolved_node_id != UNKNOWN_NODEID); // lookup if the name resolver was able to canonically resolve this or not
From: Philip Herron <herron.philip@googlemail.com> This keeps the resolution code in line with paths. Addresses #2723 gcc/rust/ChangeLog: * typecheck/rust-hir-type-check-type.cc: remove hack --- gcc/rust/typecheck/rust-hir-type-check-type.cc | 16 ---------------- 1 file changed, 16 deletions(-)