Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
ff3b9501
Commit
ff3b9501
authored
Jul 08, 2019
by
Mark OLESEN
Committed by
Andrew Heather
Jul 08, 2019
Browse files
COMP: erroneous double definition for long IO on windows (
#1360
,
#1238
)
- mingw uses 32-bit long regardless of -m32 or -m64 setting
parent
eaacf0a2
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/OpenFOAM/primitives/ints/int64/int64.H
View file @
ff3b9501
...
...
@@ -119,10 +119,10 @@ inline bool read(const std::string& str, int64_t& val)
Istream
&
operator
>>
(
Istream
&
is
,
int64_t
&
val
);
Ostream
&
operator
<<
(
Ostream
&
os
,
const
int64_t
val
);
// On Darwin
and Windows (mingw)
:
// On Darwin:
// long is not unambiguously (int32_t | int64_t)
// - explicitly resolve for input and output
#if defined(__APPLE__)
|| defined(_WIN32)
#if defined(__APPLE__)
Istream
&
operator
>>
(
Istream
&
is
,
long
&
val
);
Ostream
&
operator
<<
(
Ostream
&
os
,
const
long
val
);
#endif
...
...
src/OpenFOAM/primitives/ints/int64/int64IO.C
View file @
ff3b9501
...
...
@@ -125,7 +125,7 @@ Foam::Ostream& Foam::operator<<(Ostream& os, const int64_t val)
}
#if defined(__APPLE__)
|| defined(_WIN32)
#if defined(__APPLE__)
Foam
::
Istream
&
Foam
::
operator
>>
(
Istream
&
is
,
long
&
val
)
{
return
operator
>>
(
is
,
reinterpret_cast
<
int64_t
&>
(
val
));
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment