IF Computer > MINERVA > Manual > Reference > Predicates > Atomic term processing > parse_atom/2/3

parse_atom/2/3

MINERVA
ifcomputer logo
f
Expert Services on the Web

Parses the characters of an atom as MINERVA term and retrieves information about variables.

parse_atom(+Atom, -Term)
parse_atom(+Atom, -Term, +Options)

parse_atom/3 parses the characters of the atom Atom like read/2.
parse_atom/3 parses the characters of the atom Atom. It behaves like read_term/3.

Elements of the Options-list can be:

variables(-Vars)
variable_names(-VarList)
singletons(-VarList)

Arguments

Atom                   atom
Term                   term
Options                list of options

Examples

parse_atom('member(X, [X|L])', Term, [variable_names(VarNames),singletons(Singletons)]).

->

Term = member(_1, [_1|_2]) VarNames = ['X' = _1, 'L' = _2] Singletons = ['L' = _2]

Standard

These predicates are not part of the ISO-Prolog Standard.

See also

write_atom/2, writeq_atom/2.

document: http://www.ifcomputer.co.jp/MINERVA/Manual/Reference/Predicates/atomic_term/parse_atom/print_en.html
published 2008/10/13 update 2003/2/25 (c) 1996-2006 IF Computer Japan
IF Computer 5-28-2 Sendagi, Bunkyo-ku Tel +81-3-5814-3352 start (AT) ifcomputer.com
Customer Support Tokyo 113-0022 Japan   http://www.ifcomputer.com
Back> managed with ubiCMS