blob: 70bf3b735567f1418a4b423efbaab8227f11f57e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
// file : libbutl/manifest-types.mxx -*- C++ -*-
// copyright : Copyright (c) 2014-2019 Code Synthesis Ltd
// license : MIT; see accompanying LICENSE file
#ifndef __cpp_modules
#pragma once
#endif
// C includes.
#ifndef __cpp_lib_modules
#include <string>
#include <cstdint> // uint64_t
#endif
// Other includes.
#ifdef __cpp_modules
export module butl.manifest_types;
#ifdef __cpp_lib_modules
import std.core;
#endif
#else
#endif
#include <libbutl/export.hxx>
LIBBUTL_MODEXPORT namespace butl
{
class manifest_name_value
{
public:
std::string name;
std::string value;
std::uint64_t name_line;
std::uint64_t name_column;
std::uint64_t value_line;
std::uint64_t value_column;
std::uint64_t start_pos; // Position of name/value-starting character.
std::uint64_t colon_pos; // Position of name/value-separating ':'.
std::uint64_t end_pos; // Position of name/value-terminating '\n' or EOF.
bool
empty () const {return name.empty () && value.empty ();}
};
}
|