<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Oct 29, 2008, at 8:58 PM, Zhongxing Xu wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div><div id=":1cv" class="ArwC7c ckChnd"><Not certain if we need E->IngoreParens()->getInit().</div><br>Perhaps. We'd better have a consistent Parenthesis handle scheme. The current one looks ad hoc (or I haven't get it from the code?).</div></span></blockquote><div><br></div><div>I realized that it's actually not needed.   Visit() just ignores ParenExprs and visits the subexpression, and GetSVal also ignores ParenExprs and looks at their children.</div><div><br></div><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 14px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><blockquote class="gmail_quote" style="border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); margin-top: 0pt; margin-right: 0pt; margin-bottom: 0pt; margin-left: 0.8ex; padding-left: 1ex; "><span class="Apple-style-span" style="color: rgb(20, 79, 174); -webkit-text-stroke-width: -1; ">+</span></blockquote><blockquote class="gmail_quote" style="border-left-width: 1px; border-left-style: solid; border-left-color: rgb(204, 204, 204); margin-top: 0pt; margin-right: 0pt; margin-bottom: 0pt; margin-left: 0.8ex; padding-left: 1ex; ">+  if (Loc::IsLocType(T) || T->isIntegerType()) {<br>+    // FIXME: to be implemented.<br>+    MakeNode(Dst, E, Pred, state);<br>+    return;<br>+  }<br><br>Is this possible?  Can InitListExpr have one of these types?</blockquote><div><br>There is one example in test/Analysis/stack-addr-ps.c. In the last function.</div></span></blockquote></div><br><div>Right!  It seems to me that in this case the InitListExpr will contain only 1 scalar value, and we should just return the SVal for that.  So something like this:</div><div><br></div><div>if (Loc::isLocType(T) || T->isIntegerType()) {</div><div>  assert (E->getNumInits() == 1);</div><div>  NodeSet Tmp;</div><div>  Expr* Init = E->getInit(0);</div><div>  Visit(Tmp, Init, Pred, state);</div><div>  for (NodeSet::iterator I=Tmp.begin(), EI=Tmp.end(); I!+EI; ++I)</div><div>   MakeNode(Dst, E, *I, SetSVal(state, Ex, GetSVal(state, Init)));</div><div>}</div><div><br></div><div><br></div></body></html>