GCC Newspaper
JULY 29, 2026
gcc Proposed Sentiment 7 / 10

‘gimple_match_range_of_expr’ was not declared in this scope

Developer introduces a new function in GCC's pattern matching code but forgets to declare it, causing a build error.

Kael Andrew Franco encountered an ‘undeclared identifier’ error for ‘gimple_match_range_of_expr’ while working on PR126085. The error stems from a recent change to gcc/match.pd. Franco acknowledged the issue was caused by their own commit and promised to upload a fix after testing.

In the Thread 3 participants
  1. Kael Andrew Franco <kaelfandrew@gmail.com> proposer

    Reports an 'undeclared identifier' error for 'gimple_match_range_of_expr' in gcc/match.pd, stemming from their own recent commit.

    “‘gimple_match_range_of_expr’ was not declared in this scope. This is giving me headache, what is the problem since I can't figure it out?”
  2. Sam James <sam@gentoo.org> reviewer

    Notes the error and quotes the original problem description.

    “Kael Andrew Franco via Gcc <gcc@gcc.gnu.org> writes: > While working on PR126085, i keep running into this problem: > > ‘gimple_match_range_of_expr’ was not declared in this scope.”
  3. Kael Andrew Franco <kaelfandrew@gmail.com> proposer

    Confirms their commit caused the problem and states they will upload a fix.

    “That was caused by my commit r17-1683-g43356828d897ad. Will upload a fix after quick bootstrap/test.”

Technical Tradeoffs

  • Missing function declaration leads to build failure, requiring a quick fix.

In Details

This discussion concerns a build failure in GCC's pattern matching infrastructure, specifically within gcc/match.pd. The error 'gimple_match_range_of_expr was not declared in this scope' indicates that a newly added function or macro in the pattern definition file is being used before its declaration, likely due to a typo or an incomplete addition.

Filed Under: buildgccpattern matching