mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-22 02:05:01 +00:00
Use numeric_limits instead of LLONG_MAX
This is a build fix for configurations where LLONG_MAX is not defined in system headers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@250946 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
bcb3afc5fb
commit
8a10a4556b
@ -18,7 +18,7 @@
|
||||
#include "llvm/Support/Format.h"
|
||||
#include "llvm/Support/raw_ostream.h"
|
||||
#include <cassert>
|
||||
#include <climits>
|
||||
#include <limits>
|
||||
using namespace llvm;
|
||||
using namespace dwarf;
|
||||
using namespace syntax;
|
||||
@ -565,7 +565,7 @@ Optional<uint64_t> DWARFFormValue::getAsUnsignedConstant() const {
|
||||
|
||||
Optional<int64_t> DWARFFormValue::getAsSignedConstant() const {
|
||||
if ((!isFormClass(FC_Constant) && !isFormClass(FC_Flag)) ||
|
||||
(Form == DW_FORM_udata && uint64_t(LLONG_MAX) < Value.uval))
|
||||
(Form == DW_FORM_udata && uint64_t(std::numeric_limits<int64_t>::max()) < Value.uval))
|
||||
return None;
|
||||
switch (Form) {
|
||||
case DW_FORM_data4:
|
||||
|
Loading…
x
Reference in New Issue
Block a user