public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/109641] Gfortran fails to overload intrinsic operator (*) if operands are complex. It works with real ones. Date: Thu, 18 May 2023 16:54:45 +0000 [thread overview] Message-ID: <bug-109641-4-G4awhQaIyL@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-109641-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109641 --- Comment #17 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-13 branch has been updated by Harald Anlauf <anlauf@gcc.gnu.org>: https://gcc.gnu.org/g:611be07e48956c8b7371eb580eef124990114fd3 commit r13-7353-g611be07e48956c8b7371eb580eef124990114fd3 Author: Harald Anlauf <anlauf@gmx.de> Date: Fri May 5 21:22:12 2023 +0200 Fortran: overloading of intrinsic binary operators [PR109641] Fortran allows overloading of intrinsic operators also for operands of numeric intrinsic types. The intrinsic operator versions are used according to the rules of F2018 table 10.2 and imply type conversion as long as the operand ranks are conformable. Otherwise no type conversion shall be performed to allow the resolution of a matching user-defined operator. gcc/fortran/ChangeLog: PR fortran/109641 * arith.cc (eval_intrinsic): Check conformability of ranks of operands for intrinsic binary operators before performing type conversions. * gfortran.h (gfc_op_rank_conformable): Add prototype. * resolve.cc (resolve_operator): Check conformability of ranks of operands for intrinsic binary operators before performing type conversions. (gfc_op_rank_conformable): New helper function to compare ranks of operands of binary operator. gcc/testsuite/ChangeLog: PR fortran/109641 * gfortran.dg/overload_5.f90: New test. (cherry picked from commit 185da7c2014ba41f38dd62cc719873ebf020b076)
next prev parent reply other threads:[~2023-05-18 16:54 UTC|newest] Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-04-27 1:41 [Bug fortran/109641] New: " adelson.oliveira at gmail dot com 2023-04-27 18:04 ` [Bug fortran/109641] " anlauf at gcc dot gnu.org 2023-04-27 19:21 ` anlauf at gcc dot gnu.org 2023-04-27 20:15 ` anlauf at gcc dot gnu.org 2023-04-27 20:54 ` anlauf at gcc dot gnu.org 2023-04-28 0:34 ` adelson.oliveira at gmail dot com 2023-04-28 1:15 ` kargl at gcc dot gnu.org 2023-04-28 1:35 ` adelson.oliveira at gmail dot com 2023-04-28 1:37 ` adelson.oliveira at gmail dot com 2023-04-28 2:21 ` sgk at troutmask dot apl.washington.edu 2023-04-28 21:07 ` anlauf at gcc dot gnu.org 2023-04-29 2:20 ` adelson.oliveira at gmail dot com 2023-04-29 19:00 ` anlauf at gcc dot gnu.org 2023-04-30 2:55 ` adelson.oliveira at gmail dot com 2023-04-30 23:19 ` adelson.oliveira at gmail dot com 2023-05-01 16:31 ` anlauf at gcc dot gnu.org 2023-05-05 19:23 ` cvs-commit at gcc dot gnu.org 2023-05-18 16:54 ` cvs-commit at gcc dot gnu.org [this message] 2023-05-18 17:01 ` anlauf at gcc dot gnu.org 2023-05-19 0:41 ` adelson.oliveira at gmail dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-109641-4-G4awhQaIyL@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).