[Nice-commit] Nice/src/gnu/expr ClassExp.java,1.10,1.11
Brought to you by:
bonniot
From: <bo...@us...> - 2003-02-19 14:16:19
|
Update of /cvsroot/nice/Nice/src/gnu/expr In directory sc8-pr-cvs1:/tmp/cvs-serv17402/src/gnu/expr Modified Files: ClassExp.java Log Message: Check global variable initialization value for captured variables (partly fixes #686142). Index: ClassExp.java =================================================================== RCS file: /cvsroot/nice/Nice/src/gnu/expr/ClassExp.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ClassExp.java 11 Oct 2002 12:09:41 -0000 1.10 --- ClassExp.java 19 Feb 2003 14:16:13 -0000 1.11 *************** *** 553,556 **** --- 553,564 ---- child = child.nextSibling) walker.walkLambdaExp(child); + + // Walk static fields. This is particularly important for + // those initialized to some value, since that value might + // include closures that need to be walked. + for (Declaration decl = firstDecl(); decl != null; + decl = decl.nextDecl()) + if (decl.isStatic() && decl.value != null) + walker.walkExpression(decl.value); } finally |