Struct SourceLineInfo

Synopsis

#include <include/internal/catch_common.h>

struct SourceLineInfo

Description

No description yet.

Mentioned in

Methods

SourceLineInfo overload
empty

Mentioned in

operator<
operator= overload
operator==

Source

Lines 47-66 in include/internal/catch_common.h.

struct SourceLineInfo {
    SourceLineInfo() = delete;
    SourceLineInfo( char const* _file, std::size_t _line ) noexcept
    :   file( _file ),
        line( _line )
    {}
    SourceLineInfo( SourceLineInfo const& other )            = default;
    SourceLineInfo& operator = ( SourceLineInfo const& )     = default;
    SourceLineInfo( SourceLineInfo&& )              noexcept = default;
    SourceLineInfo& operator = ( SourceLineInfo&& ) noexcept = default;
    bool empty() const noexcept { return file[0] == '\0'; }
    bool operator == ( SourceLineInfo const& other ) const noexcept;
    bool operator < ( SourceLineInfo const& other ) const noexcept;
    char const* file;
    std::size_t line;
};





Add Discussion as Guest

Log in