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

Commit3887d41

Browse files
author
Thomas G. Lockhart
committed
Put parens around macro arguments for safety per D'Arcy's suggestion.
1 parent06ea3c9 commit3887d41

File tree

1 file changed

+3
-3
lines changed
  • src/include/utils

1 file changed

+3
-3
lines changed

‎src/include/utils/dt.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
* Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: dt.h,v 1.9 1997/05/23 05:10:03 thomas Exp $
11+
* $Id: dt.h,v 1.10 1997/06/03 14:07:24 thomas Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -173,7 +173,7 @@ typedef struct {
173173
* Bit mask definitions for time parsing.
174174
*/
175175

176-
#defineDTK_M(t)(0x01 <<t)
176+
#defineDTK_M(t)(0x01 <<(t))
177177

178178
#defineDTK_DATE_M(DTK_M(YEAR) | DTK_M(MONTH) | DTK_M(DAY))
179179
#defineDTK_TIME_M(DTK_M(HOUR) | DTK_M(MINUTE) | DTK_M(SECOND))
@@ -241,7 +241,7 @@ typedef struct {
241241
#defineTIMESPAN_NOT_FINITE(j)TIMESPAN_IS_INVALID(j)
242242

243243
#defineTIME_PREC 1e-6
244-
#defineJROUND(j) (rint(((double)j)/TIME_PREC)*TIME_PREC)
244+
#defineJROUND(j) (rint(((double)(j))/TIME_PREC)*TIME_PREC)
245245

246246
/*
247247
* dt.c prototypes

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp