Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #35317

Syntax error on token "taskTEList", VariableDeclaratorId expected after this token

Path csiph.com!aioe.org!.POSTED!not-for-mail
From parmenides <xparmenides@yahoo.com>
Newsgroups comp.lang.java.programmer
Subject Syntax error on token "taskTEList", VariableDeclaratorId expected after this token
Date Sun, 14 Aug 2016 14:29:46 +0800
Organization Aioe.org NNTP Server
Lines 28
Message-ID <nop34r$1f19$1@gioia.aioe.org> (permalink)
NNTP-Posting-Host HC7X1lkZyyqaPv99gFIOgQ.user.gioia.aioe.org
Mime-Version 1.0
Content-Type text/plain; charset=gbk; format=flowed
Content-Transfer-Encoding 7bit
X-Complaints-To abuse@aioe.org
User-Agent Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0
X-Mozilla-News-Host news://nntp.aioe.org:119
X-Notice Filtered by postfilter v. 0.8.2
Xref csiph.com comp.lang.java.programmer:35317

Show key headers only | View raw


Hi,

In a JSP page, the following code:

<%
...
ArrayList<TaskTableEntry> taskTEList;
@SuppressWarnings("unchecked")
taskTEList = (ArrayList<TaskTableEntry>)session.getAttribute("taskTEList");
...
%>

will result in compilling error:

Syntax error on token "taskTEList", VariableDeclaratorId expected after 
this token

But, by modifing the code as:

<%
...
@SuppressWarnings("unchecked")
ArrayList<TaskTableEntry> taskTEList = 
(ArrayList<TaskTableEntry>)session.getAttribute("taskTEList");
...
%>

there is no the above error message at all. Why?

Back to comp.lang.java.programmer | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

Syntax error on token "taskTEList", VariableDeclaratorId expected after this token parmenides <xparmenides@yahoo.com> - 2016-08-14 14:29 +0800
  Re: Syntax error on token "taskTEList", VariableDeclaratorId expected after this token Lew <lewbloch@gmail.com> - 2016-08-14 12:50 -0700

csiph-web