summaryrefslogtreecommitdiffstats
path: root/lib/puppet/parser
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet/parser')
-rw-r--r--lib/puppet/parser/ast.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/puppet/parser/ast.rb b/lib/puppet/parser/ast.rb
index 4c2f699c0..1918f60e9 100644
--- a/lib/puppet/parser/ast.rb
+++ b/lib/puppet/parser/ast.rb
@@ -11,6 +11,8 @@ module Puppet
class ASTError < RuntimeError; end
#---------------------------------------------------------------
class AST
+ Puppet.setdefault(:typecheck, true)
+ Puppet.setdefault(:paramcheck, true)
attr_accessor :line, :file, :parent
@@pink = ""
@@ -482,6 +484,8 @@ module Puppet
# for types
objtype = @type.value
+ # This will basically always be on, but I wanted to make it at
+ # least simple to turn off if it came to that
if Puppet[:typecheck]
builtin = false
begin
@@ -492,6 +496,8 @@ module Puppet
if builtin
# we're a builtin type
#Puppet.debug "%s is a builtin type" % objtype
+ # like :typecheck, this always defaults to on, but
+ # at least it's easy to turn off if necessary
if Puppet[:paramcheck]
@params.each { |param|
#p self.name