fish-shell/src/env_dispatch.h
Johannes Altmanninger fbaa5d193d Declare functions in headers or use internal linkage (static)
Found with gcc's -Wmissing-declarations which gives warnings like

	../src/tinyexpr.cpp:61:5: warning: no previous declaration for ‘int get_arity(int)’ [-Wmissing-declarations]
	   61 | int get_arity(const int type) {

The same warnings show up for builtin functions like builtin_bg because they
currently don't include their own headers. I left that.
Also reformat the touched files.
2020-09-08 22:44:03 +02:00

22 lines
539 B
C++

// Prototypes for functions that react to environment variable changes
#ifndef FISH_ENV_DISPATCH_H
#define FISH_ENV_DISPATCH_H
#include "config.h" // IWYU pragma: keep
#include <memory>
#include "common.h"
#include "env_universal_common.h"
/// Initialize variable dispatch.
class environment_t;
void env_dispatch_init(const environment_t &vars);
class env_stack_t;
void env_dispatch_var_change(const wcstring &key, env_stack_t &vars);
void env_universal_callbacks(env_stack_t *stack, const callback_data_list_t &callbacks);
#endif