Parse a signed integer from the front of Str using Radix into Result.

Synopsis

Declared in <llvm/ADT/StringRef.h>

bool
consumeSignedInteger(
    StringRef& Str,
    unsigned int Radix,
    long long& Result);

Return Value

True on error (no conversion or overflow).

Parameters

Name

Description

Str

Input string; the consumed prefix is removed on success.

Radix

Numeric base, or 0 for autosensing.

Result

Destination for the parsed value.

Created with MrDocs