-
Notifications
You must be signed in to change notification settings - Fork 8k
Map Firebird integer field types with native php integer types #2279
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| *(zend_long *)*ptr = *(ISC_LONG*)var->sqldata; | ||
| break; | ||
| case SQL_INT64: | ||
| #if SIZEOF_ZEND_LONG >= 8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this #if should not be indented, place # at column one please.
| *len = sizeof(zend_long); | ||
| *ptr = FETCH_BUF(S->fetch_buf[colno], zend_long, 1, NULL); | ||
| *(zend_long *)*ptr = *(ISC_INT64*)var->sqldata; | ||
| #else |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this #else should not be indented, place # at column one please.
| #else | ||
| *ptr = FETCH_BUF(S->fetch_buf[colno], char, CHAR_BUF_LEN, NULL); | ||
| *len = slprintf(*ptr, CHAR_BUF_LEN, "%" LL_MASK "d", *(ISC_INT64*)var->sqldata); | ||
| #endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this #endif should not be indented, place # at column one please.
| switch (var->sqltype & ~1) { | ||
| case SQL_SHORT: | ||
| case SQL_LONG: | ||
| #if SIZEOF_ZEND_LONG >= 8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this #if should not be indented, place # at column one please.
| case SQL_LONG: | ||
| #if SIZEOF_ZEND_LONG >= 8 | ||
| case SQL_INT64: | ||
| #endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this #endif should not be indented, place # at column one please.
|
Adjusted conditional directives to match coding standards. Able to merge in master & 7.x branches. |
| $S = $C->prepare('select aint, asmi from atable'); | ||
| $S->execute(); | ||
| $D = $S->fetch(PDO::FETCH_NUM); | ||
| echo gettype($D[0]).PHP_EOL.gettype($D[1]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PHP_EOL will produce different output, if the test is run on a Apache SAPI. It's better to use "\n" or just var_dump().
|
Merged as 826122f. Thanks! |
|
For reference: after merge discussion here about easing bc: http://externals.io/thread/591 |
More info here: https://bugs.php.net/bug.php?id=72583
Related test attached.