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

SCM Repository

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

Annotation of /branches/vis12/bugs/resolved/bug005.diderot

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2158 - (view) (download)

1 : jhr 2150 /*! \file bug005.diderot
2 :     *
3 :     * \author John Reppy
4 :     */
5 :    
6 :     /*
7 :     * COPYRIGHT (c) 2013 The Diderot Project (http://diderot-language.cs.uchicago.edu)
8 :     * All rights reserved.
9 :     */
10 :    
11 :     /* this fails to compile because the parameter name for id is the same as an already declared
12 :     * global.
13 :     *
14 :     * % ../../bin/diderotc --exec bug005.diderot
15 :     * [bug005.diderot:3.19-25] Error: redefinition of 'x', previous definition at [bug005.diderot:1.1-2.0]
16 :     *
17 :     * we should allow this redefinition, since the parameter list is a new scope (do we want a warning?)
18 :     */
19 :    
20 :     real x = 1.0;
21 :    
22 :     function real id (real x) = x;
23 :    
24 :     strand Dummy ()
25 :     {
26 :     output int out = 1;
27 :     update { stabilize; }
28 :     }
29 :    
30 :     initially { Dummy() | i in 1..2 };

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