mparser

A matlab lexer and parser written with ANTLR, with a mex interface.
1K download
Aggiornato 1 set 2011

Visualizza la licenza

This is a MATLAB lexer and parser written using ANTLR. The goal of
this package is to provide a way to parse MATLAB code from within
MATLAB, and to be able to do source code translations on the resulting
AST.

The main workhorse of this package is "mparser", a MEX file which
accepts either a string or a filename and parses it into a deeply
nested set of MATLAB structures representing an AST. These can
examined and manipulated from within MATLAB.

Includes a variety of other tools to parse and examine matlab code.

While I have made every effort to be as exact as I can, there are
still a few differences between this grammar and the "true" MATLAB
grammar. Most of these you will never notice, but there are a few
that are significant:

* The transpose operator ' is not supported (due to lexing confusion
with the single quotes used in string constants).

* Constant matrices and cells must have individual elements separated
by a comma.

* Block comments are not supported.

For others, please see the comments in matlab.g
Hopefully, future versions will remedy this.

Cita come

David Wingate (2026). mparser (https://it.mathworks.com/matlabcentral/fileexchange/32769-mparser), MATLAB Central File Exchange. Recuperato .

Compatibilità della release di MATLAB
Creato con R2010b
Compatibile con qualsiasi release
Compatibilità della piattaforma
Windows macOS Linux
Categorie
Scopri di più su String Parsing in Help Center e MATLAB Answers
Versione Pubblicato Note della release
1.0.0.0