llvm / llvm/llvm-project

[mlir] parseFunctionSignature doesn't report error for missing empty result type

Open
#206,186 2 comments 0 reactions 0 assignees View on GitHub
mlir
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

If I call `call_interface_impl::parseFunctionSignature` with `mustParseEmptyResult` set to true, but the function call I'm parsing does not have an explicit empty return, the function returns failure without having reported an error. Other errors that this function can encounter are reported. I came across this via CIR, where we were expecting this function to report errors, so parsing silently failed when I hit a call without the explicit empty return.

Contributor guide

Open the contributing guide

Research direction

Start by locating call_interface_impl::parseFunctionSignature and the existing tests for its parsing errors. Reproduce the mustParseEmptyResult case with a call lacking an explicit empty return, then verify that it reports an error instead of only returning failure.

Written by the indexing model from the issue text.

Assessment

Domain
compilers
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.