Name

allocate-foreign-object — Allocates an instance of a foreign object. Macro

Syntax

	  allocate-foreign-object type &optional size => ptr
	

Arguments and Values

type

The type of foreign object to allocate. This parameter is evaluated.

size

An optional size parameter that is evaluated. If specified, allocates and returns an array of type that is size members long. This parameter is evaluated.

ptr

A pointer to the foreign object.

Description

Allocates an instance of a foreign object. It returns a pointer to the object.

Examples

(def-struct ab (a :int) (b :double))
(allocate-foreign-object 'ab)
=> #<ptr>
	

Side Effects

None.

Affected by

None.

Exceptional Situations

None.