hg: valhalla/valhalla/langtools: Add support for tracking 'any'-related opcodes

John Rose john.r.rose at oracle.com
Thu Jul 24 20:44:09 UTC 2014

On Jul 24, 2014, at 9:19 AM, Remi Forax <forax at univ-mlv.fr> wrote:

> new if different of anewarray, i don't think you can specialize new.
> anewarray is equivalent to getfield, the syntax use an internal name instead of a descriptor which is an historical glitch in my opinion

FTR, here's a standing proposal to patch over that historical glitch (break glass in case of emergency):

  - If the string foo is a valid class name, then Lfoo; is a valid descriptor (existing rule)
  - If the string bar is a valid descriptor, then .bar is a valid class name (new rule)
  - But, L.foo; is never a valid descriptor (normality condition, excluding '.' from descriptors)

If (which is not necessarily true) the dot only ever needs to appear in the leading position of a CONSTANT_Class string, then we can also consider (equivalently) introducing a new type CONSTANT_Signature and allow it to occur in some places CONSTANT_Class is valid today.  In that case, the "leading dot" notation could still be useful when rendering descriptors as class name strings.

— John

More information about the valhalla-dev mailing list