This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 196755 - AssertionError: The same token (index: 544 - UNKNOWN_TOKEN) was precessed before. Please report this to help fix issue 188809. <?php $this->breadcrumbs = array( 'Tools'=>array('/tools'), 'Photo',
Summary: AssertionError: The same token (index: 544 - UNKNOWN_TOKEN) was precessed be...
Status: RESOLVED FIXED
Alias: None
Product: php
Classification: Unclassified
Component: Editor (show other bugs)
Version: 7.0
Hardware: All All
: P3 normal (vote)
Assignee: Petr Pisl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-16 08:45 UTC by sapauljoseph
Modified: 2011-06-16 19:57 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 174634


Attachments
stacktrace (9.60 KB, text/plain)
2011-03-16 08:45 UTC, sapauljoseph
Details

Note You need to log in before you can comment on or make changes to this bug.
Description sapauljoseph 2011-03-16 08:45:53 UTC
Build: NetBeans IDE 7.0 Beta 2 (Build 201102140001)
VM: Java HotSpot(TM) 64-Bit Server VM, 19.1-b02-334, Java(TM) SE Runtime Environment, 1.6.0_24-b07-334-10M3326
OS: Mac OS X

User Comments:
GUEST: auto complete an object method in PHP after a single arrow and it threw this Java Exception

karel_barel: Trying to create PHPUnit tests using menu Tools / Create PHPUnit tests

GUEST: code completion php getcwd()




Stacktrace: 
java.lang.AssertionError: The same token (index: 544 - UNKNOWN_TOKEN)  was precessed before.
Please report this to help fix issue 188809.

<?php
$this->breadcrumbs = array(
	'Tools'=>array('/tools'),
	'Photo',
);
switch(Yii::app()->request->getQuery('for', 'user')) {
	case 'user':
		$user = Users::model()->find('ID=:id', array(':id'=>Yii::app()->request->getQuery('id', 'null')));
		if($user !== null) {
			switch(Yii::app()->request->getQuery('action', 'gallery')) {
				case 'gallery':
					$pics = UserPics::model()->findAll('UserID=:id', array(':id'=>$user->ID));
					if(count($pics) > 0) {
						// Show the pictures as Thumbnails
						echo '<h3>Pick any of your existing Pictures</h3>';
						echo '<table border="0" cellpadding="10" cellspacing="0"><tr>';
						$row = 0;
						foreach ($pics as $pic) {
							$row++;
							if($row % 5 == 0) {
								echo '</tr><tr>';
							}
							echo '<td align="center"><img src="'.Yii::app()->baseUrl.'/users/'.$pic->UserID.'/'.$pic->ID.'.'.$pic->Type.'" width="150" />
   at org.netbeans.modules.php.editor.indent.FormatVisitor.showAssertionFor188809(FormatVisitor.java:1048)
   at org.netbeans.modules.php.editor.indent.FormatVisitor.addFormatToken(FormatVisitor.java:1059)
   at org.netbeans.modules.php.editor.indent.FormatVisitor.visit(FormatVisitor.java:395)
   at org.netbeans.modules.php.editor.parser.astnodes.Block.accept(Block.java:96)
   at org.netbeans.modules.php.editor.parser.astnodes.visitors.DefaultVisitor.scan(DefaultVisitor.java:54)
   at org.netbeans.modules.php.editor.indent.FormatVisitor.scan(FormatVisitor.java:188)
Comment 1 sapauljoseph 2011-03-16 08:45:57 UTC
Created attachment 107036 [details]
stacktrace
Comment 2 OndrejBrejla 2011-03-16 14:06:40 UTC
Maybe it's somehow connected with http://netbeans.org/bugzilla/show_bug.cgi?id=191867
Comment 3 Petr Pisl 2011-06-07 15:13:40 UTC
It's reproducible. I will fix it.
Comment 4 Petr Pisl 2011-06-15 17:24:46 UTC
Fixed all cases in web-main and releases/release701.
Comment 5 Quality Engineering 2011-06-16 19:57:20 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/562d5a3b3b19
User: Petr Pisl <ppisl@netbeans.org>
Log: #196755 - AssertionError: The same token (index: 544 - UNKNOWN_TOKEN) was precessed before.