354 Commits

Author SHA1 Message Date
ian%hixie.ch
2cb93aea42 Forgot a dependency
git-svn-id: svn://10.0.0.236/trunk@140407 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 20:28:40 +00:00
ian%hixie.ch
b58545fdc6 A simple HTTP redirection template (301)
git-svn-id: svn://10.0.0.236/trunk@140403 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 20:00:26 +00:00
ian%hixie.ch
e11da1b695 More bullet proofing for the module loading; Better handling of inherited AUTOLOADs; minor fixups.
git-svn-id: svn://10.0.0.236/trunk@140402 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:59:32 +00:00
ian%hixie.ch
f946e40330 Even neater error messages and warnings
git-svn-id: svn://10.0.0.236/trunk@140401 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:58:17 +00:00
ian%hixie.ch
54de5c8842 Slap some duct tape around the output module to keep it together for now. Eventually this will have to be vastly simplified.
git-svn-id: svn://10.0.0.236/trunk@140400 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:54:12 +00:00
ian%hixie.ch
441cd7e2bc Comment out the debug code in the DESTROY handler
git-svn-id: svn://10.0.0.236/trunk@140399 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:52:23 +00:00
ian%hixie.ch
56f854aaad Fix fallout in the Input modules from the removal of implied properties
git-svn-id: svn://10.0.0.236/trunk@140398 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:50:40 +00:00
ian%hixie.ch
96b493206b add a redirect string, fix the other strings to corectly send back their data.
git-svn-id: svn://10.0.0.236/trunk@140397 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:48:52 +00:00
ian%hixie.ch
d8d6070167 Fix build bustage
git-svn-id: svn://10.0.0.236/trunk@140396 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 19:47:57 +00:00
ian%hixie.ch
afb1a224ac typo fix
git-svn-id: svn://10.0.0.236/trunk@140385 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-27 14:59:26 +00:00
ian%hixie.ch
557994668e disabling a signal handler isn't done by using undef
git-svn-id: svn://10.0.0.236/trunk@139519 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-15 15:07:34 +00:00
ian%hixie.ch
685ed52c3d fix the non-compiled case
git-svn-id: svn://10.0.0.236/trunk@139518 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-15 14:53:35 +00:00
ian%hixie.ch
d0e1d3a931 remove DESTROY code, rework the output system to use a single hash instead of passing arguments around, delay the loading of certain modules, fix some bugs with the removal of the built in property system, make the TemplateToolkit module only have one template object, and cache the precompiled documents, remove the HTTP output module, and other optimisations.
git-svn-id: svn://10.0.0.236/trunk@139517 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-15 14:14:21 +00:00
ian%hixie.ch
dcb58218de Improve the Exception class so it can work out what 'eval' numbers map to; remove the 'properties' stuff since it was taking a good 4% of the overall time of PLIF applications. THIS WILL CAUSE HUGE PROBLEMS WITH PLIF CONSUMERS. I REPEAT, THIS **WILL** BREAK YOUR CODE. DO NOT UPDATE TO THIS CODE IF YOU DON'T WANT TO SPEND A LOT OF TIME UPDATING YOUR CODE\!\!\!
git-svn-id: svn://10.0.0.236/trunk@139447 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 13:08:43 +00:00
ian%hixie.ch
4015b54a02 Stop perl parsing source files that aren't used. (Lazy loading using __DATA__ blocks)
git-svn-id: svn://10.0.0.236/trunk@139442 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 07:50:18 +00:00
ian%hixie.ch
8d5a9a0bea Fix the error handling of compiled templates
git-svn-id: svn://10.0.0.236/trunk@139427 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 03:59:29 +00:00
ian%hixie.ch
ba35e2f60a Minor optimisation. There was no point doing named expanders.
git-svn-id: svn://10.0.0.236/trunk@139426 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 03:58:46 +00:00
ian%hixie.ch
d59428fc57 UTF-8 baby.
git-svn-id: svn://10.0.0.236/trunk@139425 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 03:57:13 +00:00
ian%hixie.ch
558798af98 More debugging information
git-svn-id: svn://10.0.0.236/trunk@139419 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 02:16:09 +00:00
ian%hixie.ch
c5c4e57fc9 Support compiled templates in a separate directory
git-svn-id: svn://10.0.0.236/trunk@139418 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 02:13:03 +00:00
ian%hixie.ch
4c2bd4b790 This script can be used to quickly compile any TemplateToolkit templates
git-svn-id: svn://10.0.0.236/trunk@139417 18797224-902f-48f8-a5cc-f745e15eee43
2003-03-14 02:08:04 +00:00
ian%hixie.ch
0b93adb7f0 Make sure to stringify the error string.
git-svn-id: svn://10.0.0.236/trunk@136388 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-15 23:48:41 +00:00
ian%hixie.ch
a5cb60580b Don't try to call the inherited DESTROY destructor, since UNIVERSAL doesn't have one...
git-svn-id: svn://10.0.0.236/trunk@136106 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-10 00:36:20 +00:00
ian%hixie.ch
0afe61ae12 Propogate errors from the results frame for a nicer stack trace.
git-svn-id: svn://10.0.0.236/trunk@136103 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-10 00:21:08 +00:00
ian%hixie.ch
f72992785a Support negative integers too
git-svn-id: svn://10.0.0.236/trunk@136102 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-10 00:20:37 +00:00
ian%hixie.ch
6491fc1049 TemplateToolkit doesn't support .defined on objects. Also, stringify objects early to avoid trying to apply .replace, etc, on them.
git-svn-id: svn://10.0.0.236/trunk@136101 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-10 00:19:47 +00:00
ian%hixie.ch
baa0546c6d PATH_INFO support.
git-svn-id: svn://10.0.0.236/trunk@136100 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-10 00:14:45 +00:00
ian%hixie.ch
e376750c1d Escape newlines in keys. Explicitly mention empty arrays and hashes. Quote string values. Support undefined values.
git-svn-id: svn://10.0.0.236/trunk@135864 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-05 23:47:15 +00:00
ian%hixie.ch
e6ec1b20e3 Oops, forgot to escape the backslashes when I pasted my TemplateToolkit file into Perl.
git-svn-id: svn://10.0.0.236/trunk@135801 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-03 00:47:32 +00:00
ian%hixie.ch
7f09c2f1fb Switch to a hopefully much faster debug.dumpVars template
git-svn-id: svn://10.0.0.236/trunk@135800 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-03 00:24:27 +00:00
ian%hixie.ch
194002b5b9 Three new filters: pad left, pad right, and indent lines, so that the first line can be indented a different amoun.
git-svn-id: svn://10.0.0.236/trunk@135796 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-02 22:32:42 +00:00
ian%hixie.ch
a3008e0a68 Turns out sprintf() is redundant with the format filter, so removing it.
git-svn-id: svn://10.0.0.236/trunk@135792 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-02 21:47:12 +00:00
ian%hixie.ch
ce64a85119 Make methodMissing use syntaxError instead of error(). Remove all the user level, error reporting and fatal handlers nonsense. Remove the debug() method. Update error() and assert() to be simply quick shortcuts to raising exceptions, using deep magic to make the stacktraces look good.
git-svn-id: svn://10.0.0.236/trunk@135788 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-02 20:39:49 +00:00
ian%hixie.ch
e59ea54e7a Propagate PLIF::Exceptions through TemplateToolkit code without stringifying them.
git-svn-id: svn://10.0.0.236/trunk@135786 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-02 20:34:27 +00:00
ian%hixie.ch
77d0568da4 Make report also return the exception, so it can be reported and raised at the same time (useful for debugging). Make reraising of exceptions not wipe out the original stacktrace. Clean up stringification: Cope with calls from eval '...' blocks and sub { ... } blocks, also dump the environment, don't stringify object arguments, escape newlines in string arguments.
git-svn-id: svn://10.0.0.236/trunk@135785 18797224-902f-48f8-a5cc-f745e15eee43
2003-01-02 20:33:10 +00:00
ian%hixie.ch
823749eae6 Add some singulars up at the mulit-year level.
git-svn-id: svn://10.0.0.236/trunk@135745 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-31 23:36:59 +00:00
ian%hixie.ch
a94380c4e3 Nicer alignment.
git-svn-id: svn://10.0.0.236/trunk@135744 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-31 23:23:12 +00:00
ian%hixie.ch
a55e66c036 Replace Carp.pm with Exception.pm so that we have a consistent interface to exceptions and errors. Also add a syntaxError check in AUTOLOAD to make sure we don't call it when we shouldn't.
git-svn-id: svn://10.0.0.236/trunk@135707 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 08:04:29 +00:00
ian%hixie.ch
c73fee76ea Neaten up the arguments display: limit the depth, allow integers to be unquoted as well as floats, crop long strings.
git-svn-id: svn://10.0.0.236/trunk@135706 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 08:02:40 +00:00
ian%hixie.ch
8265b3ec37 Remove bogus argument, and add error checking code to catch similar errors in future
git-svn-id: svn://10.0.0.236/trunk@135704 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 07:52:19 +00:00
ian%hixie.ch
da7a28fc8e Export the syntaxError function, which reports a syntax error where the caller was invoked.
git-svn-id: svn://10.0.0.236/trunk@135698 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 07:30:43 +00:00
ian%hixie.ch
d75258c737 Reduce the number of sites that call 'caller'. Let's hope that this doesn't get optimised too much, or else the line numbers will start getting increasingly inaccurate...
git-svn-id: svn://10.0.0.236/trunk@135697 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 07:28:45 +00:00
ian%hixie.ch
20964a11b5 Add support for reporting Exceptions as warnings, for parity with, and so that PLIF can transition from, Carp.pm
git-svn-id: svn://10.0.0.236/trunk@135696 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 07:06:34 +00:00
ian%hixie.ch
91fd7737aa Remove debugging code that accidentally got checked in.
git-svn-id: svn://10.0.0.236/trunk@135694 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 06:43:27 +00:00
ian%hixie.ch
40245c1eb3 Clean up the stack trace code: make stacktrace smarter about where the exception should be reported from, make it know about the arguments to the functions, make the stringifier know about try{} blocks
git-svn-id: svn://10.0.0.236/trunk@135693 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-30 06:40:05 +00:00
ian%hixie.ch
73054a5523 Additional comments explaining what might happen in cases of key clashes.
git-svn-id: svn://10.0.0.236/trunk@135686 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-29 21:02:59 +00:00
ian%hixie.ch
127d2d9bdf Minor grammatical fix.
git-svn-id: svn://10.0.0.236/trunk@135685 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-29 21:02:22 +00:00
ian%hixie.ch
3e837c2278 Fixing the support for the 'attempt()' method on databases, which was broken while fixing the fallout from the Exception stuff.
git-svn-id: svn://10.0.0.236/trunk@135680 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-29 03:56:00 +00:00
ian%hixie.ch
99315a2625 Allow catch...with statements to not be followed by anything. Also add a little debug code.
git-svn-id: svn://10.0.0.236/trunk@135673 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-28 18:24:27 +00:00
ian%hixie.ch
f7054d1562 Unify the statement execution methods so that we can have consistent exception raising
git-svn-id: svn://10.0.0.236/trunk@135672 18797224-902f-48f8-a5cc-f745e15eee43
2002-12-28 18:23:24 +00:00