pike.git/
src/
program.c
Branch:
Tag:
Non-build tags
All tags
No tags
2001-12-14
2001-12-14 10:03:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>
54ecf6fbed27ef2bea0c02f4332eaa90d1876367 (
29
lines) (+
16
/-
13
)
[
Show
|
Annotate
]
Branch:
7.9
Fix for [bug
2504 (#2504)
].
Rev: src/program.c:1.391
5:
\*/ /**/ #include "global.h"
-
RCSID("$Id: program.c,v 1.
390
2001/12/14
04
:
09
:
07
mast
Exp $");
+
RCSID("$Id: program.c,v 1.
391
2001/12/14
10
:
03
:
53
grubba
Exp $");
#include "program.h" #include "object.h" #include "dynamic_buffer.h"
6264:
PMOD_EXPORT void change_compiler_compatibility(int major, int minor) {
+
if(major == PIKE_MAJOR_VERSION && minor == PIKE_MINOR_VERSION)
+
{
+
push_int(0); /* optimization */
+
} else {
if(major == Pike_compiler->compat_major && minor == Pike_compiler->compat_minor) {
-
+
/* Optimization -- reuse the current compat handler. */
if (compat_handler) {
-
add_
ref(compat_handler);
+
ref
_
push_object
(compat_handler);
+
} else {
+
push_int(0);
}
-
return;
-
}
-
-
if(major == PIKE_MAJOR_VERSION && minor == PIKE_MINOR_VERSION)
-
{
-
push_int(0); /* optimization */
-
}else{
+
}
else
{
push_int(major); push_int(minor); SAFE_APPLY_MASTER("get_compilation_handler",2); }
-
+
}
if(compat_handler) {