systemml-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deron Eriksson <deroneriks...@gmail.com>
Subject Auto format DML?
Date Thu, 03 Aug 2017 22:28:26 GMT
Hi,

I experimented with Atom's Beautify to see if I could automatically format
DML using their R format.

Since DML is quite similar to R, I found that making a few minor tweaks to
DML made it possible to run DML scripts through the R formatter.

DML vs R syntax differences (there may be more):
1) DML has input parameters preceded by $
2) DML has parfor
3) DML for/parfor can take unrecognized parameters such as "check=0"
4) DML functions can return multiple values
5) DML function signatures are different from R
6) certain # comments at the end of lines seem to produce
%InLiNe_IdEnTiFiEr% errors using Beautify

Does anyone happen to know if there's a way that DML could be automatically
formatted (using any tool) without needing to tweak the DML before/after
formatting due to the syntax differences?

BTW I took a look at this because currently our DML format is only defined
as having 2-space indentations (see
http://apache.github.io/systemml/contributing-to-systemml#dml-code-format),
and it would be nice if we had a standard format that could automatically
be applied to DML using a tool.

Deron

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message