Commit Graph

688 Commits

Author SHA1 Message Date
Andrei Zmievski
e6146d6bf3 Fix typo. 2000-02-26 16:21:29 +00:00
Zeev Suraski
80782eff1f Fix comparisons of "inf"=="inf" and "-inf"=="-inf"
@- Comparing the string "inf" with "inf" returned false - fixed (Zeev)
2000-02-26 04:07:03 +00:00
Zeev Suraski
33a564c971 Use the fast cache here too 2000-02-25 17:55:33 +00:00
Zeev Suraski
0ac9536d99 (c) patch 2000-02-19 22:46:42 +00:00
Zeev Suraski
ceba50b6ed - Fix a nasty bug in the hash, introduced in the recent migration to macros
- Make array_init() and friends trackable
2000-02-19 19:21:45 +00:00
Zeev Suraski
f77e6a4499 Generalize macros 2000-02-19 13:11:39 +00:00
Zeev Suraski
c54864e3af *** empty log message *** 2000-02-18 21:15:48 +00:00
Sascha Schumann
d7e34cf6ea Get rid of second declaration of compare_func_t. Either put in a common
header file or prefix it with i.e. zend_llist_
2000-02-18 20:04:32 +00:00
Andi Gutmans
e6b768105d - Quick and dirty hack for supporting sorts. Improve later on when I wake up. 2000-02-18 14:33:28 +00:00
Andi Gutmans
ee26ec5e9c - Didn't compile on Win32 2000-02-18 09:18:19 +00:00
Andi Gutmans
a0f2e9bf34 - Tiny change (I know I don't have to cast malloc() to void * but I like
casting my malloc()'s)
2000-02-18 00:22:20 +00:00
Andi Gutmans
18b8440c95 - Preliminary support for dynamic arrays. I need it on order to try out a
new hash implementation. It isn't used anywhere.
2000-02-18 00:14:23 +00:00
Andi Gutmans
f1a2ee55e0 - Add ZEND_API 2000-02-17 08:03:13 +00:00
Andi Gutmans
9bb9221642 -Fix bug 3504 concerning leaks with unset() 2000-02-16 16:49:44 +00:00
Andi Gutmans
9b840c5f59 - Hopefully fix Thies' bug report. 2000-02-16 16:00:02 +00:00
Zeev Suraski
2a4d65f3b8 ZEND_TEST_EXCEPTIONS should be defined/undefined before it's checked 2000-02-16 13:55:22 +00:00
Andi Gutmans
f79688e848 - Fix bug #3309 2000-02-16 09:20:10 +00:00
Andi Gutmans
7fa17e8e08 - Put in the infrastructure for the unset() fix. Right now it has the old
behavior but I just need time tomorrow to add the correct behavior.
2000-02-14 20:31:01 +00:00
Andi Gutmans
95c7788747 - Fix bug in func_get_arg()
- Get rid of compiler warnings for unused function crash()
2000-02-14 19:08:51 +00:00
Zeev Suraski
603aca0bb3 Fix a memory leak 2000-02-13 22:15:06 +00:00
Andi Gutmans
e578fad099 - Save a function call one very hash_add 2000-02-13 13:31:29 +00:00
Andi Gutmans
bb302a755c - Make startup a bit faster by changing some hash_update()'s and hash_add()'s
to hash_update_ptr()/hash_add_ptr()
2000-02-13 13:22:02 +00:00
Andi Gutmans
920b7b2841 - Fix a couple of potential bugs where we were using emalloc/efree instead
of pemalloc/pefree.
- Fix a bug were we potentially would be freeing the key by mistake
2000-02-13 12:45:36 +00:00
Zeev Suraski
81662eb8f4 *** empty log message *** 2000-02-13 01:22:11 +00:00
Zeev Suraski
0b1c8b455a Make (array) false == array() and not array(false) 2000-02-13 00:52:33 +00:00
Andrei Zmievski
94be61fde5 Made a couple of typedefs for zend_hash_apply_*() calls. 2000-02-11 21:12:49 +00:00
Zeev Suraski
2e7093d5ef Update .dsp's 2000-02-11 16:28:50 +00:00
Zeev Suraski
80bdd19e03 Fine tune Andi's patch 2000-02-11 15:59:30 +00:00
Andi Gutmans
b48eebb114 - #define ZEND_WIN32 differently 2000-02-10 17:19:10 +00:00
Andi Gutmans
bc5c9d8d7b - Finally beautify those WIN32|WINNT checks 2000-02-10 17:03:53 +00:00
Andi Gutmans
c8b321c678 - Shouldn't be there 2000-02-10 05:41:28 +00:00
Andi Gutmans
39c4687816 - Cleanup the code 2000-02-10 05:41:05 +00:00
Zeev Suraski
de8471ab4e Fix last known nasty bugs in Zend. It'll be cool if there are no new ones :) 2000-02-09 21:48:16 +00:00
Thies C. Arntzen
2e7f24a487 foreach() works now for objects as well. 2000-02-09 15:38:56 +00:00
Zeev Suraski
ebddd16c75 Fix declaration 2000-02-08 22:18:21 +00:00
Zeev Suraski
ca5622c711 Fix an elusive bug 2000-02-08 20:10:47 +00:00
Andrei Zmievski
0f1c2504b1 Fix up the patch. 2000-02-08 17:59:28 +00:00
Andrei Zmievski
c2fd6752cf Patches from Walter for strncmp() stuff. 2000-02-08 17:19:43 +00:00
Zeev Suraski
d5abab7322 Remove old unnecessary check 2000-02-07 18:53:43 +00:00
Zeev Suraski
0c470af314 Syntax highlighting was erronously emitting more than one semicolon and/or garbage with heredocs 2000-02-07 18:39:14 +00:00
Andi Gutmans
4b0da428e7 - Support the string offset syntax $a{2} with the regular array opcodes.
Will need to write new opcodes sometime but right now it's good enough
  to announce the change to this string offset syntax for beta 4.
2000-02-06 20:18:35 +00:00
Andi Gutmans
7f48989be6 - This hopefully fixes the list($a, $a) = array(1,2) crash, i.e. when list
by mistake contains the same variable twice.
- BTW, there is no defined order of assignment. The value of $a after the
  previous example is undefined, and should not be assumed to be either 1
  nor 2.
2000-02-05 20:19:46 +00:00
Zeev Suraski
b1a837ad17 More cleanup 2000-02-05 16:38:50 +00:00
Zeev Suraski
f207b3623e Pass the executor globals to internal functions 2000-02-05 15:40:05 +00:00
Zeev Suraski
9f51f154aa - Stop passing list/plist to internal functions
- Add a typedef for the pCopyConstructor function pointer
- Minor hacks
2000-02-05 15:11:24 +00:00
Zeev Suraski
ef5d72cc37 That was the broken downcasting that prevented the interactive C++ mode from working properly under UNIX 2000-02-05 01:26:15 +00:00
Zeev Suraski
b6197bcf90 Maintain a state of whether we're compiling and/or executing 2000-02-04 14:45:58 +00:00
Andrei Zmievski
e0628436f3 *** empty log message *** 2000-02-03 18:51:33 +00:00
Zeev Suraski
8b9e07dace - Fix built-in classes with more than 5 methods 2000-02-02 22:23:37 +00:00
Zeev Suraski
b3ec6d5d05 - Fix the annoying problem with list(), that surfaced up after our recent cleaning
patches
2000-02-02 16:47:43 +00:00
Andrei Zmievski
b995d2cc2f Added add_property_unset() and add_property_bool(). 2000-02-01 23:12:48 +00:00
Zeev Suraski
485412ecb1 Improve dependencies 2000-02-01 22:04:52 +00:00
Zeev Suraski
5cabf74445 Sort out a gdb problem 2000-02-01 19:22:59 +00:00
Zeev Suraski
39adeaf4f4 Fix warning 2000-02-01 18:54:01 +00:00
Andi Gutmans
131e3a06fb - Get rid of remains of garbage.
- This should fix Thies' UMR
2000-02-01 16:02:38 +00:00
Thies C. Arntzen
11f53347c7 moved destroying of garbage before resource-list gets destroyed - (see my previous mail)
zeev, andi - please comment!
2000-02-01 11:41:15 +00:00
Thies C. Arntzen
8c4ab98e17 added missing break. 2000-02-01 11:37:33 +00:00
Thies C. Arntzen
d6afe4bac7 took out zend_hash_pointer_update() & zend_hash_pointer_index_update_or_next_insert() - i really prefer link-errors instead of runtime-errors, don't you? 2000-02-01 10:40:05 +00:00
Andi Gutmans
45686e3a55 - This has to always be done. 2000-01-31 21:09:14 +00:00
Zeev Suraski
f2d3ce4170 - Optimized garbage mechanism
- Fixed another buglet in the parser
2000-01-31 19:18:07 +00:00
Zeev Suraski
0517436bf9 - Fix foreach()
- Fix indirect reference with object properties
2000-01-31 18:21:54 +00:00
Andi Gutmans
fdbca7526f - Fix the bug Thies found where I forgot to change a break; to NEXT_OPCODE();
- If you find anymore let me know
2000-01-30 21:17:29 +00:00
Andi Gutmans
0296bba808 - Run it on align_test 2000-01-30 04:49:43 +00:00
Zeev Suraski
400f464307 Fix ``'s 2000-01-29 17:49:05 +00:00
Zeev Suraski
ad115d2088 Fix require() 2000-01-29 17:19:47 +00:00
Andi Gutmans
6864e05ae3 - Get rid of another rule which isn't needed. 2000-01-29 10:20:05 +00:00
Andi Gutmans
7663e4f65e - Add parser support for string offsets. This added three shift/reduce
conflicts but they all seem to be fine.
- Cleaned up the parsing rules a bit and made them much more compact and
  elegant.
- Please CVS update and see that I didn't break anything.
2000-01-29 10:16:04 +00:00
Andi Gutmans
b862a8b728 - This will save some memory w/ GCC compilers on some platforms 2000-01-29 09:14:22 +00:00
Andi Gutmans
5da185594c - Yet another tiny optimization. 2000-01-29 00:33:07 +00:00
Andi Gutmans
336bf35a2c - Make loop a bit faster. 2000-01-28 22:23:28 +00:00
Andi Gutmans
059b64efbe - Make sure its use is understood. 2000-01-28 21:46:07 +00:00
Andi Gutmans
c23056719e - Double the speed of some key switch() tests for Win32. 2000-01-28 21:43:46 +00:00
Andi Gutmans
6f63373bb2 - This makes the switch() statement twice as quick. Moving to enum
might make this a general speed up for other platforms too
2000-01-28 13:25:55 +00:00
Andi Gutmans
8b9765a917 - Keep objects as references. 2000-01-26 21:10:46 +00:00
Andi Gutmans
4585f7bf1f - Allow is_ref to become 0 in case the refcount is back to 1. 2000-01-26 05:03:22 +00:00
Andi Gutmans
58a0844b1c - Make foreach() now copy the array but use the original array. It can
still be optimized A LOT but it's only a performance issue and not
  a feature issue.
2000-01-24 19:04:07 +00:00
Zeev Suraski
fafbf6d8da - Implement declare() with declarables framework
- Implement ticks - Germany&Norway - 5 points!
2000-01-24 19:00:30 +00:00
Zeev Suraski
adec56938e Fixes 2000-01-24 17:29:15 +00:00
Zeev Suraski
e6ba28b680 Fix an elusive bug 2000-01-22 17:02:48 +00:00
Zeev Suraski
c3677ca907 Add some order... 2000-01-20 14:26:31 +00:00
Zeev Suraski
92633067af Indentation fixes 2000-01-20 05:27:57 +00:00
Andi Gutmans
af2ef0830a - Optimize zend_hash_del a tiny bit. 2000-01-19 19:47:16 +00:00
Andi Gutmans
aa73f6b68f - Hopefully fix the hash problem. 2000-01-19 19:44:32 +00:00
Andi Gutmans
7271c050a3 - Hrm I'm not concentrating 2000-01-19 18:14:20 +00:00
Andi Gutmans
99783fe795 - Actually the destructor should run after the data is already detached
from the hash but before the bucket is freed.
2000-01-19 18:12:05 +00:00
Andi Gutmans
d3690efffe - Rollback hash_apply and friends. They assume now that hash_del is reentrant
as it first applies the destructor and only later nukes the bucket
2000-01-19 18:05:16 +00:00
Andi Gutmans
b7b97df93f - Run destructor before the hash structure is modified, thus, making
hash_del, reentrant (BLOCK_INTERRUPTIONS needs to be made a counter now).
2000-01-19 17:39:55 +00:00
Andi Gutmans
58fb1a3922 - Undo a bug we introduced. (Another one out there). 2000-01-19 17:31:33 +00:00
Thies C. Arntzen
fb6a1b8b83 RETURN_NULL -> RETURN_NULL() // we don't want macros without an argumnet 2000-01-19 09:38:45 +00:00
Zeev Suraski
549cf0381a Leak fix 2000-01-18 22:18:17 +00:00
Thies C. Arntzen
cd377b646d RETURN_NULL & RETVAL_NULL don't need (). 2000-01-18 08:40:45 +00:00
Thies C. Arntzen
bbe2172c38 use defines 2000-01-17 19:17:58 +00:00
Zeev Suraski
19d978d1c7 Get rid of the IsPointer functionality in the hash. 2000-01-17 18:45:46 +00:00
Zeev Suraski
a965dc5b40 - Fixes a newly introduced bug in the hash 2000-01-17 18:09:03 +00:00
Zeev Suraski
62114c1806 Destructors no longer return ints, the low level problem it was intended to solve is long gone now... 2000-01-17 17:33:37 +00:00
Zeev Suraski
ee08b81aab - Make zend_hash_apply() (and friends) reentrant and much, much quicker
- Introduce zend_hash_graceful_destroy(), which allows the destructor functions to
  use zend_hash_apply() and/or zend_hash_graceful_destroy()
- Switch to zend_hash_graceful_destroy() in the resource list shutdowns
2000-01-16 20:59:03 +00:00
Zeev Suraski
dc0e663241 Allow module startup to be separate from the compiler/executor startup 2000-01-16 19:41:15 +00:00
Thies C. Arntzen
bd375505f7 make the ht->inconsistent stuff less ugly:) 2000-01-16 09:45:10 +00:00
Zeev Suraski
caaeb9ff12 Fix a bug in call_user_function_ex() 2000-01-15 22:52:24 +00:00
Zeev Suraski
470fe972f5 Added support for $foo->{$bar}["foobar"] notation (was supported in PHP 3) 2000-01-15 17:17:32 +00:00