From a0074c3d3b3b294db593b942e6fa42426c097994 Mon Sep 17 00:00:00 2001 From: jjenista Date: Wed, 1 Jun 2011 23:50:01 +0000 Subject: [PATCH] if a static field is encountered, ignore it gracefully --- .../src/IR/Flat/BCXPointsToCheckVRuntime.java | 20 ++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/Robust/src/IR/Flat/BCXPointsToCheckVRuntime.java b/Robust/src/IR/Flat/BCXPointsToCheckVRuntime.java index d5439f03..50ce42e7 100644 --- a/Robust/src/IR/Flat/BCXPointsToCheckVRuntime.java +++ b/Robust/src/IR/Flat/BCXPointsToCheckVRuntime.java @@ -677,10 +677,24 @@ public class BCXPointsToCheckVRuntime implements BuildCodeExtension { output.println( buildCode.strObjType+"* objOneHop;" ); if( f != null ) { - output.println( "objOneHop = ("+buildCode.strObjType+"*) "+ - buildCode.generateTemp( context, x )+ - "->"+f.getSafeSymbol()+";"); + if( f.isStatic() ) { + + // jjenista - DON'T DEAL WITH THIS RIGHT NOW + //ClassDescriptor cdX = ; + //output.println( "objOneHop = ("+buildCode.strObjType+"*) "+ + // + // "->"+f.getSafeSymbol()+";"); + output.println( "}" ); + output.println( "}" ); + return; + + } else { + output.println( "objOneHop = ("+buildCode.strObjType+"*) "+ + buildCode.generateTemp( context, x )+ + "->"+f.getSafeSymbol()+";"); + } } else { + // element access output.println( "objOneHop = ("+buildCode.strObjType+"*) "+ "((struct "+x.getType().dereference().getSafeSymbol()+"**)"+ "(((void*) &("+buildCode.generateTemp( context, x )+"->___length___))+sizeof(int)))"+ -- 2.34.1