MLPutInteger32 has been replaced by WSPutInteger32.

int MLPutInteger32(MLINK link,int i)

puts the 32-bit integer i to the MathLink connection specified by link.


  • MLPutInteger32() returns 0 in the event of an error, and a nonzero value if the function succeeds.
  • Use MLError() to retrieve the error code if MLPutInteger32() fails.
  • You can send arbitrary-precision integers to the Wolfram Language by giving lists of digits, then converting them to numbers using FromDigits.
  • MLPutInteger32() is declared in the MathLink header file mathlink.h.


Basic Examples  (1)

#include "mathlink.h"

/* send the expression Times[10,30] to a link */

void f(MLINK lp)
    if(! MLPutFunction(lp, "Times", 2))
        { /* unable to send the function to lp */ }

    if(! MLPutInteger32(lp, 10))
        { /* unable to send the integer to lp */ }

    if(! MLPutInteger32(lp, 30))
        { /* unable to send the integer to lp */ }

    if(! MLEndPacket(lp))
        { /* unable to send the end-of-packet sequence to lp */ }

    if(! MLFlush(lp))
        { /* unable flush any buffered outgoing data in lp */ }

See Also

MLPutInteger16()  MLPutInteger64()