XDS-based TRANSEC Puts Megos Back on Track
Modula-2 to C++ converter TRANSEC enabled Megos AG to continue development
of its application software in their favorite language, with the option to
switch over to industry standard C++ tools in almost no time at any point
in the future. "Our customers would not rely on software developed using
outdated and unsupported tools. The rapid decline of Modula-2 popularity
had forced us to migrate to a more favored language," said Rene Brunner,
company vice president of Megos AG and head of the system software department.
"On the other hand, TRANSEC is capable of converting our entire code base to
highly readable and maintainable C++ within minutes. So we decided that we
can safely stay with Modula-2 for development, at least until hiring a person
knowing that language becomes a real problem."
Megos AG is the oldest independent software house in Switzerland. Its main
business is standard software for the banking sector (accounting, portfolio
management) and custom-tailored software for a wide range of companies,
unique software written for the specific needs of their customers.
In the early Nineties Megos developed a proprietary CASE system. The core
of that system was a large component library called EMBASSY written in Modula-2,
implemented as a 16-bit runtime on Microsoft Windows.
Around 1997 the transition to 32 bits became important. Unfortunately it
turned out to be rather difficult to find suitable Modula-2 compilers for
the Win32 API because Modula-2 in general was not very popular any more.
An additional difficulty was concerns of some customers about the use of
such a language: They would rather prefer a more "standard" and more widely
used programming language like C or C++.
Megos decided to follow a two-way strategy with the help of a program that
translates Modula-2 code to C/C++ code, which is then compiled by a C/C++
compiler. Given a translator that is fast enough and that generates readable
C/C++ code it is possible to continue writing programs in Modula-2 for the
near term but switching completely to C/C++ in the future.
A market survey showed that the XDS Modula-2 compilers/translators were
already surprisingly near these requirements. Megos decided to work together
with XDS (now Excelsior) for the development of a special version of the XDS-C
translator, code named TRANSEC (short for "(Trans)lating (E)MBASSY to (C)/C++").
The work started with a two-week design phase during the visit of Mr. Brunner
to Novosibirsk. "I met the people, learned about their way of working and
thinking, and established a relationship of trust and mutual respect with
them. This was very beneficial for the whole project," said Brunner.
The high translation speed and code quality of the original translator was
preserved and the readability of the generated code - crucial for the desired
two-way strategy with a future switch to C/C++ - improved beyond the already
rather good readability of the original translated code. "We use TRANSEC as
a "normal" Modula-2 compiler and usually do not really care whether it
generates object code directly or C++ as an intermediate step that must
be compiled itself again", said Brunner.
EMBASSY is probably one of the largest Modula-2 systems still around worldwide
and has high demands concerning development tools. Megos found many bugs in
Modula-2 compilers used earlier for building the EMBASSY runtime system.
With the XDS translators there were very few such problems, all of them
"Translating code from one programming language to another and translating
it well is a surprisingly tricky business," said Brunner. "Only a system
built from the ground up using high engineering standards by people who
really understand programming will achieve good results in this discipline.
The successful implementation of TRANSEC showed that quite clearly."