Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
ogs
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Chaofan Chen
ogs
Commits
5082c9b6
Verified
Commit
5082c9b6
authored
2 years ago
by
Christoph Lehmann
Committed by
Lars Bilke
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[BL] Made functions consteval compatible
The solution is outlined on
https://stackoverflow.com/a/68675384
parent
604dcb5c
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
BaseLib/Logging.h
+10
-10
10 additions, 10 deletions
BaseLib/Logging.h
with
10 additions
and
10 deletions
BaseLib/Logging.h
+
10
−
10
View file @
5082c9b6
...
@@ -26,27 +26,27 @@ void initOGSLogger(std::string const& log_level);
...
@@ -26,27 +26,27 @@ void initOGSLogger(std::string const& log_level);
}
// namespace BaseLib
}
// namespace BaseLib
template
<
typename
...
Args
>
template
<
typename
...
Args
>
void
DBUG
(
char
const
*
fmt
,
Args
const
&
...
args
)
void
DBUG
(
fmt
::
format_string
<
Args
...
>
fmt
,
Args
&
&
...
args
)
{
{
BaseLib
::
console
->
debug
(
fmt
,
args
...);
BaseLib
::
console
->
debug
(
fmt
,
std
::
forward
<
Args
>
(
args
)
...);
}
}
template
<
typename
...
Args
>
template
<
typename
...
Args
>
void
INFO
(
char
const
*
fmt
,
Args
const
&
...
args
)
void
INFO
(
fmt
::
format_string
<
Args
...
>
fmt
,
Args
&
&
...
args
)
{
{
BaseLib
::
console
->
info
(
fmt
,
args
...);
BaseLib
::
console
->
info
(
fmt
,
std
::
forward
<
Args
>
(
args
)
...);
}
}
template
<
typename
...
Args
>
template
<
typename
...
Args
>
void
WARN
(
char
const
*
fmt
,
Args
const
&
...
args
)
void
WARN
(
fmt
::
format_string
<
Args
...
>
fmt
,
Args
&
&
...
args
)
{
{
BaseLib
::
console
->
warn
(
fmt
,
args
...);
BaseLib
::
console
->
warn
(
fmt
,
std
::
forward
<
Args
>
(
args
)
...);
}
}
template
<
typename
...
Args
>
template
<
typename
...
Args
>
void
ERR
(
char
const
*
fmt
,
Args
const
&
...
args
)
void
ERR
(
fmt
::
format_string
<
Args
...
>
fmt
,
Args
&
&
...
args
)
{
{
BaseLib
::
console
->
error
(
fmt
,
args
...);
BaseLib
::
console
->
error
(
fmt
,
std
::
forward
<
Args
>
(
args
)
...);
}
}
template
<
typename
...
Args
>
template
<
typename
...
Args
>
void
CRITICAL
(
char
const
*
fmt
,
Args
const
&
...
args
)
void
CRITICAL
(
fmt
::
format_string
<
Args
...
>
fmt
,
Args
&
&
...
args
)
{
{
BaseLib
::
console
->
critical
(
fmt
,
args
...);
BaseLib
::
console
->
critical
(
fmt
,
std
::
forward
<
Args
>
(
args
)
...);
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment