Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
WAST::TextFileLocus Struct Reference

#include <WAST.h>

Collaboration diagram for WAST::TextFileLocus:

Public Member Functions

 TextFileLocus ()
 
U32 lineNumber () const
 
U32 column (U32 spacesPerTab=4) const
 
std::string describe (U32 spacesPerTab=4) const
 

Public Attributes

std::string sourceLine
 
U32 newlines
 
U32 tabs
 
U32 characters
 

Detailed Description

Definition at line 14 of file WAST.h.

Constructor & Destructor Documentation

◆ TextFileLocus()

WAST::TextFileLocus::TextFileLocus ( )
inline

Definition at line 21 of file WAST.h.

21: newlines(0), tabs(0), characters(0) {}

Member Function Documentation

◆ column()

U32 WAST::TextFileLocus::column ( U32 spacesPerTab = 4) const
inline

Definition at line 24 of file WAST.h.

24{ return tabs * spacesPerTab + characters + 1; }
Here is the caller graph for this function:

◆ describe()

std::string WAST::TextFileLocus::describe ( U32 spacesPerTab = 4) const
inline

Definition at line 26 of file WAST.h.

27 {
28 return std::to_string(lineNumber()) + ":" + std::to_string(column(spacesPerTab));
29 }
U32 column(U32 spacesPerTab=4) const
Definition WAST.h:24
U32 lineNumber() const
Definition WAST.h:23
Here is the call graph for this function:
Here is the caller graph for this function:

◆ lineNumber()

U32 WAST::TextFileLocus::lineNumber ( ) const
inline

Definition at line 23 of file WAST.h.

23{ return newlines + 1; }
Here is the caller graph for this function:

Member Data Documentation

◆ characters

U32 WAST::TextFileLocus::characters

Definition at line 19 of file WAST.h.

◆ newlines

U32 WAST::TextFileLocus::newlines

Definition at line 17 of file WAST.h.

◆ sourceLine

std::string WAST::TextFileLocus::sourceLine

Definition at line 16 of file WAST.h.

◆ tabs

U32 WAST::TextFileLocus::tabs

Definition at line 18 of file WAST.h.


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