mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: remove get_event_mutable()
We can now return mutable/imutable depending on const-ness of the parameter, owing to parameter overloading. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
b8c7b173c6
commit
5960fb7340
4 changed files with 5 additions and 6 deletions
|
@ -221,7 +221,7 @@ int get_cylinder_index(const struct dive *dive, const struct event *ev)
|
|||
return best < 0 ? 0 : best;
|
||||
}
|
||||
|
||||
struct event *get_next_event_mutable(struct event *event, const std::string &name)
|
||||
struct event *get_next_event(struct event *event, const std::string &name)
|
||||
{
|
||||
if (name.empty())
|
||||
return NULL;
|
||||
|
@ -235,7 +235,7 @@ struct event *get_next_event_mutable(struct event *event, const std::string &nam
|
|||
|
||||
const struct event *get_next_event(const struct event *event, const std::string &name)
|
||||
{
|
||||
return get_next_event_mutable((struct event *)event, name);
|
||||
return get_next_event((struct event *)event, name);
|
||||
}
|
||||
|
||||
static int count_events(const struct divecomputer *dc)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue