[flang-commits] [PATCH] D142769: [flang] Fix defined I/O semantics crash & missing errors that exposed it
Peter Klausler via Phabricator via flang-commits
flang-commits at lists.llvm.org
Fri Jan 27 09:55:06 PST 2023
klausler created this revision.
klausler added a reviewer: vdonaldson.
klausler added a project: Flang.
Herald added subscribers: sunshaoce, jdoerfert.
Herald added a reviewer: sscalpone.
Herald added a project: All.
klausler requested review of this revision.
Semantics crashes when emitting runtime derived type information tables
for a type that has user-defined I/O procedures declared outside the
type with explicit INTERFACE blocks (as opposed to a GENERIC binding
within the type). This is due to the runtime table constructor
adding a table entry for each specific procedure of any explicit interface
of the right kind (e.g., READ(UNFORMATTED)) that it found, rather than
just the ones that pertain to the derived type in question. But
semantics also wasn't checking such interfaces for distinguishable
specific procedures, either.
Clean these up, improve the spelling of defined I/O procedure kinds
in error messages ("read(formatted)" rather than "READFORMATTED"),
and make error messages stemming from macro expansions only have
one "error:" prefix on the original message so that a new test
would work.
https://reviews.llvm.org/D142769
Files:
flang/lib/Decimal/big-radix-floating-point.h
flang/lib/Evaluate/characteristics.cpp
flang/lib/Parser/provenance.cpp
flang/lib/Semantics/check-declarations.cpp
flang/lib/Semantics/runtime-type-info.cpp
flang/test/Semantics/generic05.F90
flang/test/Semantics/io11.f90
flang/test/Semantics/resolve65.f90
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D142769.492827.patch
Type: text/x-patch
Size: 13527 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/flang-commits/attachments/20230127/cef87a67/attachment-0001.bin>
More information about the flang-commits
mailing list