tag/Type: require C++

This commit is contained in:
Max Kellermann 2023-03-06 15:17:41 +01:00
parent 118b76a8f1
commit 7a46c57ef3
19 changed files with 20 additions and 31 deletions

View File

@ -20,7 +20,7 @@
#include "FingerprintCommands.hxx"
#include "OtherCommands.hxx"
#include "Permission.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include "Partition.hxx"
#include "Instance.hxx"
#include "client/Client.hxx"

View File

@ -8,7 +8,7 @@
#include "client/Response.hxx"
#include "TagPrint.hxx"
#include "tag/ParseName.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include "util/StringAPI.hxx"
CommandResult

View File

@ -6,7 +6,7 @@
#include "client/Client.hxx"
#include "client/Response.hxx"
#include "tag/ParseName.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include "queue/Playlist.hxx"
#include <fmt/format.h>

View File

@ -5,7 +5,7 @@
#define MPD_DATABASE_SELECTION_HXX
#include "protocol/RangeArg.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include <string>

View File

@ -7,7 +7,7 @@
#include "../DecoderAPI.hxx"
#include "input/InputStream.hxx"
#include "tag/Handler.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include "util/Domain.hxx"
#include "Log.hxx"

View File

@ -4,7 +4,7 @@
#pragma once
#include "protocol/RangeArg.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
struct Queue;
class SongFilter;

View File

@ -12,7 +12,7 @@
#include "PrioritySongFilter.hxx"
#include "pcm/AudioParser.hxx"
#include "tag/ParseName.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include "time/ISO8601.hxx"
#include "lib/fmt/RuntimeError.hxx"
#include "util/CharUtil.hxx"

View File

@ -4,7 +4,7 @@
#ifndef MPD_TAG_BUILDER_HXX
#define MPD_TAG_BUILDER_HXX
#include "Type.h"
#include "Type.hxx"
#include "Chrono.hxx"
#include <memory>

View File

@ -4,7 +4,7 @@
#include "Config.hxx"
#include "Settings.hxx"
#include "ParseName.hxx"
#include "Type.h"
#include "Type.hxx"
#include "config/Data.hxx"
#include "config/Option.hxx"
#include "lib/fmt/RuntimeError.hxx"

View File

@ -4,7 +4,7 @@
#ifndef MPD_TAG_FALLBACK_HXX
#define MPD_TAG_FALLBACK_HXX
#include "Type.h"
#include "Type.hxx"
#include <utility>

View File

@ -31,7 +31,7 @@ main(int argc, char **argv)
fprintf(out,
"#include \"ParseName.hxx\"\n"
"#include \"Type.h\"\n"
"#include \"Type.hxx\"\n"
"\n"
"#include <assert.h>\n"
"#include <string.h>\n"

View File

@ -3,7 +3,7 @@
#include "Id3MusicBrainz.hxx"
#include "Table.hxx"
#include "Type.h"
#include "Type.hxx"
const struct tag_table musicbrainz_txxx_tags[] = {
{ "ALBUMARTISTSORT", TAG_ALBUM_ARTIST_SORT },

View File

@ -3,7 +3,7 @@
#pragma once
#include "Type.h"
#include "Type.hxx"
#include <array>

View File

@ -5,6 +5,7 @@
#define MPD_TAG_PARSE_NAME_HXX
#include <cstdint>
#include <string_view>
enum TagType : uint8_t;

View File

@ -2,6 +2,6 @@
// Copyright The Music Player Daemon Project
#include "Settings.hxx"
#include "Type.h"
#include "Type.hxx"
TagMask global_tag_mask = TagMask::All() & ~TagMask(TAG_COMMENT);

View File

@ -4,7 +4,7 @@
#ifndef MPD_TAG_TABLE_HXX
#define MPD_TAG_TABLE_HXX
#include "Type.h"
#include "Type.hxx"
#include <string_view>

View File

@ -4,7 +4,7 @@
#ifndef MPD_TAG_HXX
#define MPD_TAG_HXX
#include "Type.h" // IWYU pragma: export
#include "Type.hxx" // IWYU pragma: export
#include "Item.hxx" // IWYU pragma: export
#include "Chrono.hxx"
#include "util/DereferenceIterator.hxx"

View File

@ -1,24 +1,14 @@
// SPDX-License-Identifier: GPL-2.0-or-later
// Copyright The Music Player Daemon Project
#ifndef MPD_TAG_TYPE_H
#define MPD_TAG_TYPE_H
#pragma once
#ifdef __cplusplus
#include <cstdint>
#endif
/**
* Codes for the type of a tag item.
*/
enum TagType
#ifdef __cplusplus
/* the size of this enum is 1 byte; this is only relevant for C++
code; the only C sources including this header don't use instances
of this enum, they only refer to the integer values */
: uint8_t
#endif
{
enum TagType : uint8_t {
TAG_ARTIST,
TAG_ARTIST_SORT,
TAG_ALBUM,
@ -56,5 +46,3 @@ enum TagType
TAG_NUM_OF_ITEM_TYPES
};
#endif

View File

@ -4,7 +4,7 @@
#include "MakeTag.hxx"
#include "song/TagSongFilter.hxx"
#include "song/LightSong.hxx"
#include "tag/Type.h"
#include "tag/Type.hxx"
#include "lib/icu/Init.hxx"
#include <gtest/gtest.h>