]> err.no Git - varnish/commit
Implement a facility for source file modularization in the VCL
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 9 Mar 2007 10:31:29 +0000 (10:31 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Fri, 9 Mar 2007 10:31:29 +0000 (10:31 +0000)
commit950f236ad5fb699a67179005afa46fd83ed5be0c
tree0e3d5e11bba69f436ec7088407cafe29a233f4e1
parent2d89b34bb9df21128c949913ae8dfb035648c52b
Implement a facility for source file modularization in the VCL
compiler.  The syntax is:

include "filename" ;

Unlike the C preprocessors #include directive, a VCL include can
appear anywhere in the sourcefile:

if {req.Cookie == include "cookie.vcl" ; || !req.Host } {
}

and have cookie.vcl contain just:

"8435398475983275293759843"

Technically this results in a change to how we account for source
code references in the counter/profile table as well, and as a result
the entire source code of the VCL program is now compiled into the
shared library for easy reference.

git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@1281 d4fa192b-c00b-0410-8231-f00ffab90ce4
varnish-cache/include/vcl.h
varnish-cache/include/vrt.h
varnish-cache/lib/libvcl/vcc_acl.c
varnish-cache/lib/libvcl/vcc_compile.c
varnish-cache/lib/libvcl/vcc_compile.h
varnish-cache/lib/libvcl/vcc_fixed_token.c
varnish-cache/lib/libvcl/vcc_gen_fixed_token.tcl
varnish-cache/lib/libvcl/vcc_token.c
varnish-cache/lib/libvcl/vcc_token_defs.h