pike.git/
src/
las.c
Branch:
Tag:
Non-build tags
All tags
No tags
2010-04-15
2010-04-15 16:54:55 by Henrik Grubbström (Grubba) <grubba@grubba.org>
c5f0695bab1879c06129b0ff54056402f0ea4e2e (
19
lines) (+
16
/-
3
)
[
Show
|
Annotate
]
Branch:
7.9
Improved error message "Indexing on illegal type.".
Fixes [bug
5423 (#5423)
].
Rev: src/las.c:1.443
2:
|| This file is part of Pike. For copyright information see COPYRIGHT. || Pike is distributed under GPL, LGPL and MPL. See the file COPYING || for more information.
-
|| $Id: las.c,v 1.
442
2009
/
11
/
20
10
:
58
:
09
grubba Exp $
+
|| $Id: las.c,v 1.
443
2010
/
04
/
15
16
:
54
:
55
grubba Exp $
*/ #include "global.h"
3470:
type_a=CAR(n)->type; type_b=CDR(n)->type; if((valid = check_indexing(type_a, type_b, n)) <= 0)
-
if(!Pike_compiler->catch_level)
+
if(!Pike_compiler->catch_level)
{
yytype_report((!valid)?REPORT_ERROR:REPORT_WARNING,
-
NULL, 0, NULL, NULL, 0, type_
b
,
+
NULL, 0, NULL, NULL, 0, type_
a
,
0, "Indexing on illegal type.");
-
+
ref_push_type_value(type_b);
+
low_yyreport((!valid)?REPORT_ERROR:REPORT_WARNING, NULL, 0,
+
type_check_system_string, 1,
+
"Index : %O.");
+
}
n->type = index_type(type_a, type_b, n); } else { copy_pike_type(n->type, mixed_type_string);
5334:
prog->num_program = num_program;
+
#ifdef PIKE_DEBUG
+
if(l_flag > 3 && n)
+
{
+
fprintf(stderr,"Evaluation ==> %d\n", ret);
+
}
+
#endif
+
return ret; }