Improve documentation of random() function.
authorHeikki Linnakangas
Thu, 24 Oct 2013 12:39:30 +0000 (15:39 +0300)
committerHeikki Linnakangas
Thu, 24 Oct 2013 12:40:23 +0000 (15:40 +0300)
Move random() and setseed() to a separate table, to have them grouped
together. Also add a notice that random() is not cryptographically secure.

Original patch by Honza Horak, although I didn't use his version.

doc/src/sgml/func.sgml

index e397386bf24ad2601cb920f8b90dc44b847c367a..2b91e6e86a0e3adb4e29c9278f2bddae08046cd7 100644 (file)
        0.785398163397448
       
 
-      
-       
-        
-         random
-        
-        random()
-       
-       dp
-       random value in the range 0.0 <= x < 1.0
-       random()
-       
-      
-
       
        
         
        42.44
       
 
-      
-       
-        
-         setseed
-        
-        setseed(dp)
-       
-       void
-       set seed for subsequent random() calls (value between -1.0 and
-       1.0, inclusive)
-       setseed(0.54823)
-       
-      
-
       
        
         
     
    
 
+  
+     shows functions for
+    generating random numbers.
+  
+
+   
+    Random Functions
+
+    
+     
+      
+       Function
+       Return Type
+       Description
+      
+     
+     
+      
+       
+        
+         random
+        
+        random()
+       
+       dp
+       random value in the range 0.0 <= x < 1.0
+      
+
+      
+       
+        
+         setseed
+        
+        setseed(dp)
+       
+       void
+       set seed for subsequent random() calls (value between -1.0 and
+       1.0, inclusive)
+      
+     
+    
+   
+
+  
+   The characteristics of the values returned by
+   random() depend
+   on the system implementation. It is not suitable for cryptographic
+   applications; see  module for an alternative.
+   
+
   
    Finally,  shows the
    available trigonometric functions.  All trigonometric functions