The Erlang code preprocessor includes functions that are used by the
The Erlang source file
Examples:
%% coding: utf-8
%% For this file we have chosen encoding = Latin-1
%% -*- coding: latin-1 -*-
Handle to the
Closes the preprocessing of a file.
Returns the default encoding of Erlang source files.
Returns a string representation of an encoding. The string
is recognized by
Takes an
Opens a file for preprocessing.
If you want to change the file name of the implicit -file()
attributes inserted during preprocessing, you can do with
Setting
If
The option
The
Equivalent to
Equivalent to
Returns the next Erlang form from the opened Erlang source file.
Tuple
Preprocesses and parses an Erlang source file.
Notice that tuple
If you want to change the file name of the implicit -file()
attributes inserted during preprocessing, you can do with
If
The option
The
Equivalent to
Read the
Option
Read the
Option
Returns the raw tokens of the next Erlang form from the opened
Erlang source file. A tuple
Preprocesses an Erlang source file returning a list of the lists
of raw tokens of each form.
Notice that the tuple
Reads the
Returns the read encoding, or
Reads the
Returns the read encoding, or
{ErrorLine, Module, ErrorDescriptor}
A string describing the error is obtained with the following call:
Module:format_error(ErrorDescriptor)