commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sam Yoon (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (BCEL-277) Resolve constant to a string representation occur NoSuchElementException in case CONSTANT_NameAndType constant.
Date Tue, 26 Jul 2016 01:50:20 GMT

    [ https://issues.apache.org/jira/browse/BCEL-277?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15393027#comment-15393027
] 

Sam Yoon commented on BCEL-277:
-------------------------------

Stack trace.

java.util.NoSuchElementException
	at java.util.StringTokenizer.nextToken(StringTokenizer.java:349)
	at org.apache.bcel.generic.InvokeInstruction.toString(InvokeInstruction.java:59)
	at org.apache.bcel.classfile.ConstantPoolTestCase.testConstantToString(ConstantPoolTestCase.java:29)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at junit.framework.TestCase.runTest(TestCase.java:176)
	at junit.framework.TestCase.runBare(TestCase.java:141)
	at junit.framework.TestResult$1.protect(TestResult.java:122)
	at junit.framework.TestResult.runProtected(TestResult.java:142)
	at junit.framework.TestResult.run(TestResult.java:125)
	at junit.framework.TestCase.run(TestCase.java:129)
	at junit.framework.TestSuite.runTest(TestSuite.java:252)
	at junit.framework.TestSuite.run(TestSuite.java:247)
	at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:86)
	at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:117)
	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:42)
	at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:253)
	at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:84)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)

> Resolve constant to a string representation occur NoSuchElementException in case CONSTANT_NameAndType
constant.
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: BCEL-277
>                 URL: https://issues.apache.org/jira/browse/BCEL-277
>             Project: Commons BCEL
>          Issue Type: Bug
>          Components: Main
>    Affects Versions: 6.0
>            Reporter: Sam Yoon
>         Attachments: ConstantPoolTestCase.java, SimpleClassWithDefaultConstructor.java,
patch
>
>
> A method that constantToString of ConstantPool class always occur NoSuchElementException
when face with costant type of CONSTANT_NameAndType.
> A reason is invalid separator for StringTokenizer that colon. It should be replaced to
empty string.
> I had pull request include ConstantPoolTestCase.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message