Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita65e9f3

Browse files
committed
Fix inconsistent equalfuncs.c behavior for FuncCall.funcformat.
Other equalfuncs.c checks on CoercionForm fields useCOMPARE_COERCIONFORM_FIELD (which makes them no-ops),but commit40c24bf neglected to make _equalFuncCalldo likewise. Fix that.This is only strictly correct if FuncCall.funcformat hasno semantic effect, instead just determining ruleutils.cdisplay formatting.40c24bf added a couple of checksin parse analysis that could break that rule; but on closerinspection, they're redundant, so just take them out again.Per report from Noah Misch.Discussion:https://postgr.es/m/20210606063331.GC297923@rfd.leadboat.com
1 parentd57eceb commita65e9f3

File tree

3 files changed

+1
-3
lines changed

3 files changed

+1
-3
lines changed

‎src/backend/nodes/equalfuncs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2420,7 +2420,7 @@ _equalFuncCall(const FuncCall *a, const FuncCall *b)
24202420
COMPARE_SCALAR_FIELD(agg_star);
24212421
COMPARE_SCALAR_FIELD(agg_distinct);
24222422
COMPARE_SCALAR_FIELD(func_variadic);
2423-
COMPARE_SCALAR_FIELD(funcformat);
2423+
COMPARE_COERCIONFORM_FIELD(funcformat);
24242424
COMPARE_LOCATION_FIELD(location);
24252425

24262426
return true;

‎src/backend/parser/parse_clause.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -543,7 +543,6 @@ transformRangeFunction(ParseState *pstate, RangeFunction *r)
543543
!fc->agg_star&&
544544
!fc->agg_distinct&&
545545
!fc->func_variadic&&
546-
fc->funcformat==COERCE_EXPLICIT_CALL&&
547546
coldeflist==NIL)
548547
{
549548
ListCell*lc;

‎src/backend/parser/parse_func.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,6 @@ ParseFuncOrColumn(ParseState *pstate, List *funcname, List *fargs,
222222
agg_order==NIL&&agg_filter==NULL&&
223223
!agg_star&& !agg_distinct&&over==NULL&&
224224
!func_variadic&&argnames==NIL&&
225-
funcformat==COERCE_EXPLICIT_CALL&&
226225
list_length(funcname)==1&&
227226
(actual_arg_types[0]==RECORDOID||
228227
ISCOMPLEX(actual_arg_types[0])));

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp