473,387 Members | 1,771 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

FunctionExpression bug in IE7 - fixed?

VK
Sorry for not having IE7 currently available.

Could anyone check if FunctionExpression bug is fixed in IE7 beta or
stay the same (it was once confirmed by IE team, but did they do
anything?)

A minimum test case:

<html>
<head>
<title>bug test</title>
<meta http-equiv="Content-Type"
content="text/html; charset=iso-8859-1">
<script>
var f = (function foo(){});
window.alert(typeof foo);
</script>
</head>
<body>
</body>
</html>

Correct value: "undefined" (FF, Opera)

IE6 reports: "function"

Sep 17 '06 #1
17 1477

VK написав:
....
var f = (function foo(){});
....
Correct value: "undefined" (FF, Opera)

IE6 reports: "function"
Can you show the cases when this can be serious bug?
I can't even imagine.

Val

Sep 17 '06 #2
sc********@gmail.com wrote:
VK напи ав:
...
>var f = (function foo(){});
...
>Correct value: "undefined" (FF, Opera)

IE6 reports: "function"

Can you show the cases when this can be serious bug?
I can't even imagine.
It is not a serious bug. JavaScript(tm) suffered from it for a long time
as well. It has never been a problem because if you really need a named
function you can just declare it in an enclosing scope and then refer to
it by name, if you don't need to refer to a function by name it can then
be anonymous with no consequences, and if you need to call an anonymous
function form inside itself you can use - arguemnts.callee - to refer to
the function.

Richard.
Sep 17 '06 #3
VK
Can you show the cases when this can be serious bug?
>
It is not a serious bug.
So is it fixed or not? :-) Anyone with the latest IE7 beta installed?

If VK is asking something, it is not always and necessary some deeply
hidden context to search for :-)) I really didn't know something and so
asked at c.l.j.

It is a really minor bug (of the level of [1,,2] array initializer or
lower) just needed to be sort out for a really small particular issue.

Sep 17 '06 #4
VK wrote:
<snip>
Anyone with the
latest IE7 beta installed?
<snip>

Do you really expect to squander so much of everyone's time and effort
and then have them go out of their way to help you?

Richard.
Sep 17 '06 #5

Richard Cornford написав:
VK wrote:
<snip>
Anyone with the
latest IE7 beta installed?
<snip>

Do you really expect to squander so much of everyone's time and effort
and then have them go out of their way to help you?

Richard.
I would like to help but I hate IE and have no version 7.
I think this bug is not fixed in IE7 because main difference between
IE6 and 7 is interface and security, not scripting.

Val

Sep 17 '06 #6
VK
sc********@gmail.com wrote:
I would like to help but I hate IE and have no version 7.
Same 1st, ACK 2nd
P.S. Did you try to give a hand to Old Silver? Poor boy, you don't know
the choice you've just made. :-)

P.P.S. Just kidding, really :-)

Sep 17 '06 #7
Hi,

sc********@gmail.com wrote:
I would like to help but I hate IE and have no version 7.
You should try IE7. Microsoft really put a lot of effort in making it
much more compliant to standards than the previous versions. In fact, in
Mix06, the IE program manager started his presentation by apologizing to
us for the errors they made in IE6. What I tested in IE7 so far
convinced me that it is probably at least as good as Firefox (I am using
both).
I think this bug is not fixed in IE7 because main difference between
IE6 and 7 is interface and security, not scripting.
I think it's worth a test, because they also fixed many bugs in all
parts of the browser.
Val
HTH,
Laurent
--
Laurent Bugnion, GalaSoft
Software engineering: http://www.galasoft-LB.ch
PhotoAlbum: http://www.galasoft-LB.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch
Sep 17 '06 #8
sc********@gmail.com wrote:
Richard Cornford напи ав:
>VK wrote:
<snip>
Anyone with the
latest IE7 beta installed?
<snip>

Do you really expect to squander so much of everyone's
time and effort and then have them go out of their way
to help you?
<snip>
I would like to help but I hate IE and have no version 7.
A willingness to help and an ability to help are often very different
things. VK has put a lot of effort into minimising the willingness to
help among people who would have the ability. What he is left with is
what he is left with.
I think this bug is not fixed in IE7
<snip>

As the bug is in JScript, and JScript uses a DLL that is independent of
the browser, there is no meaningful sense in which the bug could be
'fixed in IE 7". The question is really whether IE 7 will be distributed
with a JScript DLL update that does not feature the bug. If it were the
same DLL could feature in IE 6 updates.

Richard.
Sep 17 '06 #9

BTW even if they're fixed this bug there are dozen of other bugs in IE
;)
For example I still don't know is it a bug or not:

var dollarCheck=("$".replace(/\$/,"$$").length==1)?true:false
alert(dollarCheck)
//try it in different browsers

But I have to say that sometimes IE is much faster than other browsers
and it is a good side of IE.

Val

Sep 17 '06 #10
wrote on 17 sep 2006 in comp.lang.javascript:
>
BTW even if they're fixed this bug there are dozen of other bugs in IE
;)
For example I still don't know is it a bug or not:

var dollarCheck=("$".replace(/\$/,"$$").length==1)?true:false
(... == ...)?true:false

That is a very useful piece of code!

alert(dollarCheck)
//try it in different browsers
Nothing wrong in IE6
>
But I have to say that sometimes IE is much faster than other browsers
and it is a good side of IE.

Val
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Sep 18 '06 #11

Evertjan. написав:
var dollarCheck=("$".replace(/\$/,"$$").length==1)?true:false

(... == ...)?true:false

That is a very useful piece of code!
It only looks not useful but it was critical in application that
replaces strings using regexps.
alert(dollarCheck)
//try it in different browsers

Nothing wrong in IE6
I don't know who is wrong but it alerts different things in different
browsers.

Val

Sep 18 '06 #12
sc********@gmail.com wrote:
>(... == ...)?true:false
That is a very useful piece of code!
It only looks not useful but it was critical in application that
replaces strings using regexps.
I believe the sarcasm was to point out that the ?true:false is pointless,
since the (... == ...) already evaluates to a boolean.

Unnecessary use of true/false is often a sign of low-quality code.

--
Matt Kruse
http://www.JavascriptToolbox.com
http://www.AjaxToolbox.com
Sep 18 '06 #13
VK
<OT>
That is about the old $ sign treatment (Netscape 4.x - 6.x) and the new
one (introduced by IE 5.5 and currently adopted by others).
I am no way a RegExp specialist, but I just happened to know this issue
as I had to write many price-handling subs and this $ once drawn me
crazy for several hours. Funny thing (and I'm not acting) I used the
very same ? true:false check - because when "$$" results in "$" from
skies blue, an hour later you are starting wondering if true is still
true and false is false :-)

Namely by old rules $ sign in the replacement string was just a
character (unless $1 and stuff). So to replace "$" with "$$" it was
enough:
var foo = "$".replace(/\$/,"$$"); // "$$";
But starting from IE 5.5 (and from one of endless beta's of NN 6)
double dollar sign $$ means single dollar sign $:
var foo = "$".replace(/\$/,"$$"); // "$";
var foo = "$".replace(/\$/,"$$$$"); // "$$";
....still hate them for that... :-)
</OT>

So anyone with IE7 beta installed? (if not - so not, I have to wait
until I return home to one of test machines).

A minimum test case:

<html>
<head>
<title>bug test</title>
<meta http-equiv="Content-Type"
content="text/html; charset=iso-8859-1">
<script>
var f = (function foo(){});
window.alert(typeof foo);
</script>
</head>
<body>
</body>
</html>

Correct value: "undefined" (FF, Opera)

IE6 reports: "function"

Sep 18 '06 #14
VK wrote:
Correct value: "undefined" (FF, Opera)

IE6 reports: "function"

IE7 RC-1 on my PC also reports "function".
It appears IE7 is being distributed with a newer jscript.dll. The dll
in C:\WINDOWS\SYSTEM32\ is version 5.7.0.5700 (476kb) and the IE7
version is 7.0.5700.6. On my other PC with IE6 jscript.dll is at
version 5.6.0.8831

George.

Sep 18 '06 #15

Matt Kruse написав:
sc********@gmail.com wrote:
(... == ...)?true:false
That is a very useful piece of code!
It only looks not useful but it was critical in application that
replaces strings using regexps.

I believe the sarcasm was to point out that the ?true:false is pointless,
since the (... == ...) already evaluates to a boolean.

Unnecessary use of true/false is often a sign of low-quality code.

--
Matt Kruse
Thanks, Matt
I was so swampted with bugs and I didn't noted this issue. Sure
true:false is redundant here!

Val

Sep 18 '06 #16
VK

George3 wrote:
IE7 RC-1 on my PC also reports "function".
It appears IE7 is being distributed with a newer jscript.dll. The dll
in C:\WINDOWS\SYSTEM32\ is version 5.7.0.5700 (476kb) and the IE7
version is 7.0.5700.6. On my other PC with IE6 jscript.dll is at
version 5.6.0.8831
Thank you very much for your help

Sep 18 '06 #17
JRS: In article <ee*******************@news.demon.co.uk>, dated Sun, 17
Sep 2006 18:04:59 remote, seen in news:comp.lang.javascript, Richard
Cornford <Ri*****@litotes.demon.co.ukposted :
>VK wrote:
<snip>
>Anyone with the
latest IE7 beta installed?
<snip>

Do you really expect to squander so much of everyone's time and effort
and then have them go out of their way to help you?

There is no need for you to argue with everything that VK writes; others
can do that. It would be better to spend the time on your volunteered
task of maintaining the newsgroup FAQ - or finding someone else to do
it.

--
John Stockton, Surrey, UK. ??*@merlyn.demon.co.uk Turnpike v4.00 MIME.
Web <URL:http://www.merlyn.demon.co.uk/- FAQish topics, acronyms, & links.
Check boilerplate spelling -- error is a public sign of incompetence.
Never fully trust an article from a poster who gives no full real name.
Sep 19 '06 #18

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

26
by: Adrian Parker | last post by:
I'm using the code below in my project. When I print all of these fixed length string variables, one per line, they strings in questions do not properly pad with 0s. strQuantity prints as " ...
1
by: Jaz | last post by:
Trying to use a fixed layer for a couple of NAV buttons. I found this code, but the IE part is commented, and I don't understand the IF statement. It works great on Moz/Firebird and Opera BUT...
6
by: Mason A. Clark | last post by:
Masters: On two or three-column layouts, one column often has a list of links. Scrolling the page hides them. I'm aware there's supposed to be the ability to fix the column (frame-like). I...
9
by: pout | last post by:
What are the purposes of fixed-point? When should it be used? I read: #define Int2Fixed(x) (((long)(short)x) << 16) and the fixed-point in 16.16 format. Does the 16 in the MACRO refer to...
4
by: Otie | last post by:
Hello, I am using the MSFlexGrd Control in VB5. I have 1 fixed row and one fixed column. I am trying to do a sort when the user clicks a column in the FIXED ROW. But when I capture the row...
1
by: O.B. | last post by:
In the example below, I'm trying to convert a fixed byte array to a string. I get an error about needing to use "fixed" but I have no clue where to apply it. Help? using System; using...
1
by: Rick Knospler | last post by:
I am trying to convert a vb6 project to vb.net. The conversion worked for the most part except for the fixed length strings and fixed length string arrays. Bascially the vb6 programmer stored all...
4
by: Jeff | last post by:
Hey I'm wondering how the Fixed-Width Text Format is What I know is that the top line in this text format will contain column names. and each row beneath the top line represent for example a...
19
by: kangax | last post by:
There's a common pattern of "forking" a returning function as in the following example: function bind(fn, context) { var args = Array.prototype.slice.call(arguments, 2); if (args.length) {...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.