Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
0066f7a8
Commit
0066f7a8
authored
Nov 15, 2017
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
util/{Const,Writable}Buffer: add constructor with two pointers
parent
65059f2a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
0 deletions
+6
-0
ConstBuffer.hxx
src/util/ConstBuffer.hxx
+3
-0
WritableBuffer.hxx
src/util/WritableBuffer.hxx
+3
-0
No files found.
src/util/ConstBuffer.hxx
View file @
0066f7a8
...
@@ -109,6 +109,9 @@ struct ConstBuffer {
...
@@ -109,6 +109,9 @@ struct ConstBuffer {
constexpr
ConstBuffer
(
pointer_type
_data
,
size_type
_size
)
constexpr
ConstBuffer
(
pointer_type
_data
,
size_type
_size
)
:
data
(
_data
),
size
(
_size
)
{}
:
data
(
_data
),
size
(
_size
)
{}
constexpr
ConstBuffer
(
pointer_type
_data
,
pointer_type
_end
)
:
data
(
_data
),
size
(
_end
-
_data
)
{}
/**
/**
* Convert array to ConstBuffer instance.
* Convert array to ConstBuffer instance.
*/
*/
...
...
src/util/WritableBuffer.hxx
View file @
0066f7a8
...
@@ -103,6 +103,9 @@ struct WritableBuffer {
...
@@ -103,6 +103,9 @@ struct WritableBuffer {
constexpr
WritableBuffer
(
pointer_type
_data
,
size_type
_size
)
constexpr
WritableBuffer
(
pointer_type
_data
,
size_type
_size
)
:
data
(
_data
),
size
(
_size
)
{}
:
data
(
_data
),
size
(
_size
)
{}
constexpr
WritableBuffer
(
pointer_type
_data
,
pointer_type
_end
)
:
data
(
_data
),
size
(
_end
-
_data
)
{}
/**
/**
* Convert array to WritableBuffer instance.
* Convert array to WritableBuffer instance.
*/
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment