Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d9e79e20 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Module: Mark getters as const"

parents 09eac1c2 35807bfc
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -24,12 +24,12 @@ namespace bluetooth {
ModuleFactory::ModuleFactory(std::function<Module*()> ctor) : ctor_(ctor) {
}

Handler* Module::GetHandler() {
Handler* Module::GetHandler() const {
  ASSERT_LOG(handler_ != nullptr, "Can't get handler when it's not started");
  return handler_;
}

const ModuleRegistry* Module::GetModuleRegistry() {
const ModuleRegistry* Module::GetModuleRegistry() const {
  return registry_;
}

+2 −2
Original line number Diff line number Diff line
@@ -77,9 +77,9 @@ class Module {
  // Release all resources, you're about to be deleted
  virtual void Stop() = 0;

  ::bluetooth::os::Handler* GetHandler();
  ::bluetooth::os::Handler* GetHandler() const;

  const ModuleRegistry* GetModuleRegistry();
  const ModuleRegistry* GetModuleRegistry() const;

  template <class T>
  T* GetDependency() const {