Journal Articles

CVu Journal Vol 11, #3 - Apr 1999 + Internet Topics
Browse in : All > Journals > CVu > 113 (22)
All > Topics > Internet (35)
Any of these categories - All of these categories

Note: when you create a new publication type, the articles module will automatically use the templates user-display-[publicationtype].xt and user-summary-[publicationtype].xt. If those templates do not exist when you try to preview or display a new article, you'll get this warning :-) Please place your own templates in themes/yourtheme/modules/articles . The templates will get the extension .xt there.

Title: Web Sites to Review

Author: Administrator

Date: 03 April 1999 13:15:30 +01:00 or Sat, 03 April 1999 13:15:30 +01:00

Summary: 

Body: 

Feedback from an earlier published site:

Dear Francis,

I have just got to page 13 of C Vu 11.1 and the article about the free on-line C/C++ magazine at www.megatechsoftware.com/codermag.htm. I am always interested in anything C or C++ so I downloaded and read it.

Oh no, oh no. If it wasn't so bad it would be funny. It is probably the worst example of C coding I have seen, indicative of someone who has read only the first few chapters of a very bad C book. Unfortunately, new programmers may come across this stuff and believe such code is acceptable. This is one that should have been stopped very early on.

Examples of content:

void main(void) {
------------------------------------------------
char* MAPSIZE;             // Temp Map Size Var
  ...
sprintf(MAPSIZE, "%d", strlen(MAP_LAYER_01));
------------------------------------------------
 loop:
  ...
  goto loop;
------------------------------------------------
if((win9x_fp=fopen("c:\\windows\\command\\ansi.sys","r"))!=NULL)
        {
        fclose(win9x_fp);
        win9x_found();
        }
fclose(win9x_fp);
if((dos_fp=fopen("c:\\dos\\format.com","r"))!=NULL)
        {
        fclose(dos_fp);
        dos_found();
        }
fclose(dos_fp);
unknown_OS();
}
---------------------------------------------------

p.s. I am willing to review such sites, mailing lists, etc. if I am emailed details. I will usually respond to email within a couple of days. Since I am currently only on page 15 of C Vu 11.1 you can see how far behind I am on work-related printed magazines/journals so by the time I have read about something, I have missed at least one publication date.

Mark Easterbrook.

Some More for Members to Check

If you have a moment please have a look at one or more of the following, write a brief review and send it to me or to Peter Hamilton.

An Alternative to yacc

ANTLR is a yacc substitute (it used to be called PCCTS)that is much nicer than yacc for C++ code generation and it comes with complete C, C++, Java, etc... grammars included in the package

Take a look at <http://www.antlr.org/>. It's worth it

I think that an independent review of the following would be worthwhile. This is a posting from the authors.

Context Free Grammars

Regular languages form a subset of context free languages. Regular grammars are described by regular expressions, and can be implemented with finite state machines. Context free languages in general cannot be described by regular expressions, nor can be implemented with finite state machines. Instead, we need a machine with a stack (called push-down automaton).

Information about grammars and their implementations can be found in 'Parsing Techniques', which can be downloaded free at: http://www.cs.vu.nl/~dick/PTAPG.html

The Graph Template Library - GTL

What is GTL?

Since we are intensively working with graph algorithms especially in Graphlet (http://www.fmi.uni-passau.de/Graphlet/), we decided to implement GTL, a graph library based on STL. For the design of GTL's API the API of LEDA has served as a basis. GTL contains the classes needed to work with graphs, nodes and edges and some basic algorithms as building blocks for more complex graph algorithms. Further algorithms are under work.

FEATURES: * Datastructures for handling graphs efficiently. * Designed to be extended to fit your own needs. * Basic (extensible) graph algorithms:

  • Depth First Search (DFS)

  • Breadth First Search (BFS)

  • Topological Sorting

  • Biconnectivity Test

  • ST Numbering

  • Planarity Test with planar embedding

(ALPHA, works only on Solaris/Linux) * GML file format support (see http://www.fmi.uni-passau.de/Graphlet/) Please refer to our homepage for details.

Availability:

We are currently using GTL in Graphlet on the following platforms:

  • Solaris with egcs-1.0.3 or later.

  • Linux with egcs-1.0.3 or later.

  • MS Windows NT/95/98 and Visual C++ 5.0 Service Pack 3

The latest version is GTL-0.2.2. The source code can be downloaded from: http://www.fmi.uni-passau.de/archive/archive.theory/ftp/GTL/

Homepage:

The GTL WWW homepage is http://www.fmi.uni-passau.de/Graphlet/GTL/

Authors:

GTL is maintained by:

Michael Forster

Andreas Pick

Marcus Raitner

Design by Contract

The best support for Design by Contract in C++ that I have seen is probably Gnu's Nana (see http://www.gnu.org/manual/nana/html_mono/nana.html for introduction), download it from ftp://ftp.cs.ntu.edu.au/pub/nana; this implementation provides limited support for DBC, but some of the trickier aspects are not covered (such as inherited pre- and postconditions, which should only allow weakening of the precondition and strengthening of the postcondition).

Two things, look at the sites and review them, and perhaps someone would like to write an article (for Overload, I think, on Design by Contract.

Notes: 

More fields may be available via dynamicdata ..