From 7ff17ddfd337d1c49c1174d8d24b2ce0671b2c9e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Bj=C3=B6rn=20Gustavsson?=
Date: Mon, 12 May 2014 14:26:30 +0200
Subject: BIFs should be considered exported
All BIFs now have stub functions and are exported. For example
in the erlang module:
-export([..., is_list/1, ...]).
.
.
.
is_list(_Term) ->
erlang:nif_error(undefined).
But erlang:function_exported(erlang, is_list, 1) returns false,
which is weird.
Change erlang:function_exported/3 to return true for BIFs.
---
erts/doc/src/erlang.xml | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
(limited to 'erts/doc/src/erlang.xml')
diff --git a/erts/doc/src/erlang.xml b/erts/doc/src/erlang.xml
index 0f4dfc0f98..03d184f4d2 100644
--- a/erts/doc/src/erlang.xml
+++ b/erts/doc/src/erlang.xml
@@ -1252,10 +1252,11 @@ true
Check if a function is exported and loaded
Returns true if the module Module is loaded
- and contains an exported function Function/Arity;
- otherwise false.
- Returns false for any BIF (functions implemented in C
- rather than in Erlang).
+ and contains an exported function Function/Arity,
+ or if there is a BIF (a built-in function implemented in C)
+ with the given name; otherwise returns false.
+ This function used to return false for built-in
+ functions before the 18.0 release.
--
cgit v1.2.3