From 3003ef4854b297560d7b876db9e37c0ffc7a98e4 Mon Sep 17 00:00:00 2001 From: Matthew Sackman Date: Thu, 29 Oct 2009 12:01:23 +0000 Subject: Added specs which, importantly, feature no_return() as the return types, in order to shut up dialyzer --- src/gen_server2.erl | 11 +++++++++++ src/rabbit_plugin_activator.erl | 11 +++++++++++ 2 files changed, 22 insertions(+) diff --git a/src/gen_server2.erl b/src/gen_server2.erl index a2d9350c..9631e03b 100644 --- a/src/gen_server2.erl +++ b/src/gen_server2.erl @@ -179,6 +179,17 @@ -import(error_logger, [format/2]). +%%%========================================================================= +%%% Specs. These exist only to shut up dialyzer's warnings +%%%========================================================================= + +-ifdef(use_specs). + +-spec(handle_common_termination/6 :: + (any(), any(), any(), atom(), any(), any()) -> no_return()). + +-endif. + %%%========================================================================= %%% API %%%========================================================================= diff --git a/src/rabbit_plugin_activator.erl b/src/rabbit_plugin_activator.erl index e22d844f..a2ac74ef 100644 --- a/src/rabbit_plugin_activator.erl +++ b/src/rabbit_plugin_activator.erl @@ -38,6 +38,17 @@ -define(DefaultRabbitEBin, "ebin"). -define(BaseApps, [rabbit]). +%%---------------------------------------------------------------------------- +%% Specs +%%---------------------------------------------------------------------------- + +-ifdef(use_specs). + +-spec(start/0 :: () -> no_return()). +-spec(stop/0 :: () -> 'ok'). + +-endif. + %%---------------------------------------------------------------------------- start() -> -- cgit v1.2.1