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
67f591a9
Commit
67f591a9
authored
Aug 03, 2013
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gcc.h: add macro gcc_unreachable()
parent
105b431e
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
18 additions
and
14 deletions
+18
-14
DecoderControl.cxx
src/DecoderControl.cxx
+1
-1
OutputInit.cxx
src/OutputInit.cxx
+1
-1
ReplayGainConfig.cxx
src/ReplayGainConfig.cxx
+1
-2
audio_format.c
src/audio_format.c
+1
-1
audio_format.h
src/audio_format.h
+1
-1
FlacPcm.cxx
src/decoder/FlacPcm.cxx
+1
-1
ChainFilterPlugin.cxx
src/filter/ChainFilterPlugin.cxx
+1
-0
gcc.h
src/gcc.h
+6
-0
AlsaOutputPlugin.cxx
src/output/AlsaOutputPlugin.cxx
+1
-1
JackOutputPlugin.cxx
src/output/JackOutputPlugin.cxx
+1
-0
PcmMix.cxx
src/pcm/PcmMix.cxx
+2
-4
PcmVolume.cxx
src/pcm/PcmVolume.cxx
+1
-2
No files found.
src/DecoderControl.cxx
View file @
67f591a9
...
...
@@ -99,7 +99,7 @@ decoder_control::IsCurrentSong(const Song *_song) const
}
assert
(
false
);
return
false
;
gcc_unreachable
()
;
}
void
...
...
src/OutputInit.cxx
View file @
67f591a9
...
...
@@ -123,7 +123,7 @@ audio_output_load_mixer(struct audio_output *ao,
}
assert
(
false
);
return
NULL
;
gcc_unreachable
()
;
}
bool
...
...
src/ReplayGainConfig.cxx
View file @
67f591a9
...
...
@@ -55,9 +55,8 @@ replay_gain_get_mode_string(void)
return
"album"
;
}
/* unreachable */
assert
(
false
);
return
"off"
;
gcc_unreachable
()
;
}
bool
...
...
src/audio_format.c
View file @
67f591a9
...
...
@@ -69,7 +69,7 @@ sample_format_to_string(enum sample_format format)
/* unreachable */
assert
(
false
);
return
"?"
;
gcc_unreachable
()
;
}
const
char
*
...
...
src/audio_format.h
View file @
67f591a9
...
...
@@ -253,7 +253,7 @@ sample_format_size(enum sample_format format)
}
assert
(
false
);
return
0
;
gcc_unreachable
()
;
}
/**
...
...
src/decoder/FlacPcm.cxx
View file @
67f591a9
...
...
@@ -104,7 +104,7 @@ flac_convert(void *dest,
case
SAMPLE_FORMAT_FLOAT
:
case
SAMPLE_FORMAT_DSD
:
case
SAMPLE_FORMAT_UNDEFINED
:
/* unreachable */
assert
(
false
);
gcc_unreachable
();
}
}
src/filter/ChainFilterPlugin.cxx
View file @
67f591a9
...
...
@@ -93,6 +93,7 @@ ChainFilter::CloseUntil(const Filter *until)
/* this assertion fails if #until does not exist (anymore) */
assert
(
false
);
gcc_unreachable
();
}
static
const
struct
audio_format
*
...
...
src/gcc.h
View file @
67f591a9
...
...
@@ -79,6 +79,12 @@
#endif
#if defined(__GNUC__) || defined(__clang__)
#define gcc_unreachable() __builtin_unreachable()
#else
#define gcc_unreachable()
#endif
#ifdef __cplusplus
#ifdef __GNUC__
...
...
src/output/AlsaOutputPlugin.cxx
View file @
67f591a9
...
...
@@ -257,7 +257,7 @@ get_bitformat(enum sample_format sample_format)
}
assert
(
false
);
return
SND_PCM_FORMAT_UNKNOWN
;
gcc_unreachable
()
;
}
static
snd_pcm_format_t
...
...
src/output/JackOutputPlugin.cxx
View file @
67f591a9
...
...
@@ -696,6 +696,7 @@ mpd_jack_write_samples(JackOutput *jd, const void *src,
default:
assert
(
false
);
gcc_unreachable
();
}
}
...
...
src/pcm/PcmMix.cxx
View file @
67f591a9
...
...
@@ -110,9 +110,8 @@ pcm_add_vol(void *buffer1, const void *buffer2, size_t size,
return
true
;
}
/* unreachable */
assert
(
false
);
return
false
;
gcc_unreachable
()
;
}
template
<
typename
T
,
typename
U
,
unsigned
bits
>
...
...
@@ -184,9 +183,8 @@ pcm_add(void *buffer1, const void *buffer2, size_t size,
return
true
;
}
/* unreachable */
assert
(
false
);
return
false
;
gcc_unreachable
()
;
}
bool
...
...
src/pcm/PcmVolume.cxx
View file @
67f591a9
...
...
@@ -188,7 +188,6 @@ pcm_volume(void *buffer, size_t length,
return
true
;
}
/* unreachable */
assert
(
false
);
return
false
;
gcc_unreachable
()
;
}
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