libdonut  2.3.2
Application framework for cross-platform game development in C++20
Public Member Functions | Public Attributes | List of all members
donut::json::SourceLocation Struct Reference

Line and column numbers of a location in a JSON source string. More...

#include <donut/json.hpp>

Public Member Functions

constexpr bool operator== (const SourceLocation &other) const =default
 Compare this source location to another for equality. More...
 

Public Attributes

std::size_t lineNumber
 Line number, starting at 1 for the first line. More...
 
std::size_t columnNumber
 Column number, starting at 1 for the first column. More...
 

Detailed Description

Line and column numbers of a location in a JSON source string.

Examples
example_game.cpp.

Member Function Documentation

◆ operator==()

constexpr bool donut::json::SourceLocation::operator== ( const SourceLocation other) const
constexprdefault

Compare this source location to another for equality.

Parameters
otherthe source location to compare this one to.
Returns
true if the source locations are equal, false otherwise.

Member Data Documentation

◆ lineNumber

std::size_t donut::json::SourceLocation::lineNumber

Line number, starting at 1 for the first line.

A value of 0 means no particular line.

◆ columnNumber

std::size_t donut::json::SourceLocation::columnNumber

Column number, starting at 1 for the first column.

A value of 0 means no particular column.


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