1erl_features(3) Erlang Module Definition erl_features(3)
2
3
4
6 erl_features - Feature support.
7
9 This module contains functions for supporting features that can be en‐
10 abled/disabled in Erlang. It should be considered as mostly for inter‐
11 nal use, although there are some functions that might be useful when
12 writing tools.
13
15 feature() = atom()
16
17 release() = integer() >= 0
18
19 status() = experimental | approved | permanent | rejected
20
21 type() = extension | backwards_incompatible_change
22
24 all() -> [feature()]
25
26 Return a list of all known features. This list will include fea‐
27 tures that have been removed (status rejected) and features that
28 are no longer configurable (status permanent).
29
30 configurable() -> [feature()]
31
32 Return a list of all configurable features, that is, features
33 with status experimental or approved. These are the features
34 that can be enabled or disabled.
35
36 info(Feature :: feature()) -> FeatureInfoMap | no_return()
37
38 Types:
39
40 Description = string()
41 FeatureInfoMap =
42 #{description := Description,
43 short := Description,
44 type := type(),
45 keywords := [atom()],
46 status := status(),
47 experimental => release(),
48 approved => release(),
49 permanent => release(),
50 rejected => release()}
51
52 Return a map containing information about the given feature.
53
54 enabled() -> [feature()]
55
56 Return a list of the features that are currently enabled. Note
57 that the set of enabled is set during startup and can then not
58 be changed.
59
60 used(Module :: module() | file:filename()) -> [feature()]
61
62 Return the list of features enabled when compiling the module.
63 The module need not be loaded, but is found if it exists in the
64 loadpath. If not all features used by the module are enabled in
65 the runtime, loading the module is not allowed.
66
67
68
69Ericsson AB stdlib 4.3.1.3 erl_features(3)