summaryrefslogtreecommitdiff
path: root/system
diff options
context:
space:
mode:
authorDieter Schoen <dieter@schoen.or.at>2020-12-12 19:54:33 +0100
committerDieter Schoen <dieter@schoen.or.at>2020-12-12 19:54:33 +0100
commit852874f57ba68df754e63cd38f60f6df7d085207 (patch)
tree0b59df64242a9cff42485f511ff0acc2b6db0184 /system
parent4adeaaa8d97bf4a8c88b415a03d2dbf884e27807 (diff)
downloaderlang-852874f57ba68df754e63cd38f60f6df7d085207.tar.gz
Replace old test BIFs w/o is_ prefix in documentation code examples
Diffstat (limited to 'system')
-rw-r--r--system/doc/programming_examples/list_comprehensions.xml4
-rw-r--r--system/doc/programming_examples/records.xml2
2 files changed, 3 insertions, 3 deletions
diff --git a/system/doc/programming_examples/list_comprehensions.xml b/system/doc/programming_examples/list_comprehensions.xml
index 706cb337ad..f9ce57f478 100644
--- a/system/doc/programming_examples/list_comprehensions.xml
+++ b/system/doc/programming_examples/list_comprehensions.xml
@@ -40,10 +40,10 @@
<c>[1,2,a,...]</c> and X is greater than 3.</p>
<p>The notation <c><![CDATA[X <- [1,2,a,...]]]></c> is a generator and
the expression <c>X > 3</c> is a filter.</p>
- <p>An additional filter, <c>integer(X)</c>, can be added to restrict
+ <p>An additional filter, <c>is_integer(X)</c>, can be added to restrict
the result to integers:</p>
<pre>
-> <input>[X || X &lt;- [1,2,a,3,4,b,5,6], integer(X), X > 3].</input>
+> <input>[X || X &lt;- [1,2,a,3,4,b,5,6], is_integer(X), X > 3].</input>
[4,5,6]</pre>
<p>Generators can be combined. For example, the Cartesian product
of two lists can be written as follows:</p>
diff --git a/system/doc/programming_examples/records.xml b/system/doc/programming_examples/records.xml
index d74ce22e4e..04c06816c5 100644
--- a/system/doc/programming_examples/records.xml
+++ b/system/doc/programming_examples/records.xml
@@ -222,7 +222,7 @@ print(#person{name = Name, age = Age,
%% Demonstrates type testing, selector, updating.
-birthday(P) when record(P, person) ->
+birthday(P) when is_record(P, person) ->
P#person{age = P#person.age + 1}.
register_two_hackers() ->