clang 10.0.0git

Static Public Member Functions | Public Attributes | List of all members
clang::ParsedSourceRange Struct Reference

A source range that has been parsed on the command line. More...

`#include "clang/Frontend/CommandLineSourceLoc.h"`

Collaboration diagram for clang::ParsedSourceRange:
[legend]

## Static Public Member Functions
static Optional< ParsedSourceRange > | fromString (StringRef Str)
| Returns a parsed source range from a string or None if the string is invalid. More...

## Public Attributes
std::string | FileName
std::pair< unsigned, unsigned > | Begin
| The starting location of the range. More...
std::pair< unsigned, unsigned > | End
| The ending location of the range. More...

## Detailed Description

A source range that has been parsed on the command line.

Definition at line 54 of file CommandLineSourceLoc.h.

## Member Function Documentation

## ◆ fromString()

static Optional<ParsedSourceRange> clang::ParsedSourceRange::fromString | ( | StringRef | Str | ) |
| inline static

Returns a parsed source range from a string or None if the string is invalid.

These source string has the following format:

file:start_line:start_column[-end_line:end_column]

If the end line and column are omitted, the starting line and columns are used as the end values.

Definition at line 72 of file CommandLineSourceLoc.h.

References clang::ParsedSourceLocation::FromString(), clang::None, and Split.

## Member Data Documentation

## ◆ Begin

std::pair<unsigned, unsigned> clang::ParsedSourceRange::Begin

The starting location of the range.

The first element is the line and the second element is the column.

Definition at line 58 of file CommandLineSourceLoc.h.

## ◆ End

std::pair<unsigned, unsigned> clang::ParsedSourceRange::End

The ending location of the range.

The first element is the line and the second element is the column.

Definition at line 61 of file CommandLineSourceLoc.h.

## ◆ FileName

std::string clang::ParsedSourceRange::FileName

Definition at line 55 of file CommandLineSourceLoc.h.

The documentation for this struct was generated from the following file:

- include/clang/Frontend/CommandLineSourceLoc.h