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

Commit6114040

Browse files
committed
Small code simplifications
strVal() can be used in a couple of places instead of coding the samething by hand.
1 parent25a9e54 commit6114040

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

‎src/backend/foreign/foreign.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -544,7 +544,7 @@ deflist_to_tuplestore(ReturnSetInfo *rsinfo, List *options)
544544
nulls[0]= false;
545545
if (def->arg)
546546
{
547-
values[1]=CStringGetTextDatum(((Value*) (def->arg))->val.str);
547+
values[1]=CStringGetTextDatum(strVal(def->arg));
548548
nulls[1]= false;
549549
}
550550
else

‎src/backend/parser/gram.y

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13890,7 +13890,7 @@ func_expr_common_subexpr:
1389013890
* Convert SystemTypeName() to SystemFuncName() even though
1389113891
* at the moment they result in the same thing.
1389213892
*/
13893-
$$ = (Node *) makeFuncCall(SystemFuncName(((Value *)llast($5->names))->val.str),
13893+
$$ = (Node *) makeFuncCall(SystemFuncName(strVal(llast($5->names))),
1389413894
list_make1($3),
1389513895
COERCE_EXPLICIT_CALL,
1389613896
@1);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp