From patchwork Sat Oct 12 00:17:01 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Kargl X-Patchwork-Id: 1175620 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-510819-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=troutmask.apl.washington.edu Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="YnvjuqHs"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46qlkl3gllz9s7T for ; Sat, 12 Oct 2019 11:17:17 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:reply-to:mime-version:content-type; q=dns; s=default; b=loG29XCFXinLlpvqW6+h6V/ALieZNXBk5FauxTxf5On g/UunK7m9Xy3un5zF+YeWAHocrtqrPrfIJGkmeHRbuT39kSDhS95cX0+jn7cPtGT cI4P+nYbFvHOMhJCHcYgKALlzG5mawHqUnJ5743blPwRFY01DUFBdvaTHRdAGCQs = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:reply-to:mime-version:content-type; s=default; bh=8ISqa3MrKK0x+ptz1im4+ruw1Zw=; b=YnvjuqHscH19p8hAD 69zKEoOExTN9gukgDM3yh5PnHLR689DYh0l03jrPWDiJInlwJf3VY/HglUqyY2Os 9ETcxBS/gylYGAq2azI+xeuYXOupcIRUHcPEQ3SSPIQSmlzy2KxcrkynZUfOwjtI 0zbQ7K2z9zDciSvIwqk0Dsxszw= Received: (qmail 49065 invoked by alias); 12 Oct 2019 00:17:05 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 49050 invoked by uid 89); 12 Oct 2019 00:17:05 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-8.7 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3 autolearn=ham version=3.3.1 spammy=delays X-HELO: troutmask.apl.washington.edu Received: from troutmask.apl.washington.edu (HELO troutmask.apl.washington.edu) (128.95.76.21) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sat, 12 Oct 2019 00:17:03 +0000 Received: from troutmask.apl.washington.edu (localhost [127.0.0.1]) by troutmask.apl.washington.edu (8.15.2/8.15.2) with ESMTPS id x9C0H11D001013 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO); Fri, 11 Oct 2019 17:17:01 -0700 (PDT) (envelope-from sgk@troutmask.apl.washington.edu) Received: (from sgk@localhost) by troutmask.apl.washington.edu (8.15.2/8.15.2/Submit) id x9C0H1Ed001012; Fri, 11 Oct 2019 17:17:01 -0700 (PDT) (envelope-from sgk) Date: Fri, 11 Oct 2019 17:17:01 -0700 From: Steve Kargl To: fortran@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: [PATCH] PR fortran/90297 -- Remove code with no functional effect Message-ID: <20191012001701.GA1007@troutmask.apl.washington.edu> Reply-To: sgk@troutmask.apl.washington.edu MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.12.1 (2019-06-15) The patch is fairly self-explanatory. OK to commit? 2019-10-11 Steven G. Kargl PR fortran/90297 * resolve.c (resolve_typebound_function): Remove code with no functional effect. Index: gcc/fortran/resolve.c =================================================================== --- gcc/fortran/resolve.c (revision 276899) +++ gcc/fortran/resolve.c (working copy) @@ -6548,21 +6548,6 @@ resolve_typebound_function (gfc_expr* e) overridable = !e->value.compcall.tbp->non_overridable; if (expr && expr->ts.type == BT_CLASS && e->value.compcall.name) { - /* If the base_object is not a variable, the corresponding actual - argument expression must be stored in e->base_expression so - that the corresponding tree temporary can be used as the base - object in gfc_conv_procedure_call. */ - if (expr->expr_type != EXPR_VARIABLE) - { - gfc_actual_arglist *args; - - for (args= e->value.function.actual; args; args = args->next) - { - if (expr == args->expr) - expr = args->expr; - } - } - /* Since the typebound operators are generic, we have to ensure that any delays in resolution are corrected and that the vtab is present. */