Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Annotation of /branches/vis12/bugs/bug018.diderot
ViewVC logotype

Annotation of /branches/vis12/bugs/bug018.diderot

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2223 - (view) (download)

1 : glk 2223
2 :     // BUG: have to somehow handle (either by name-mangling or
3 :     // out-right disallowing) use of C keywords as variable names;
4 :     // e.g. case, switch, float, sizeof, static
5 :     // http://en.wikipedia.org/wiki/C_syntax#Reserved_keywords
6 :    
7 :     strand foo (int ii) {
8 :     output real bar = 0;
9 :     /* (un-comment one of the following pairs of statements) */
10 :    
11 :     int case = 10;
12 :     int jj = case;
13 :    
14 :     /*
15 :     int switch = 10;
16 :     int jj = switch;
17 :     */
18 :     /*
19 :     int float = 10;
20 :     int jj = float;
21 :     */
22 :     /*
23 :     int sizeof = 10;
24 :     int jj = sizeof;
25 :     */
26 :     /*
27 :     int static = 10;
28 :     int jj = static;
29 :     */
30 :    
31 :     update {
32 :     print (jj, "\n");
33 :     stabilize;
34 :     }
35 :     }
36 :    
37 :     initially [ foo(ii) | ii in 1..1 ];
38 :    

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0