summaryrefslogtreecommitdiffstats
path: root/lib/puppet/parser/loaded_code.rb
Commit message (Collapse)AuthorAgeFilesLines
* Renaming LoadedCode to ResourceTypeCollectionLuke Kanies2010-02-171-134/+0
| | | | Signed-off-by: Luke Kanies <luke@reductivelabs.com>
* Fixing #2596 - Node, Class, Definition are not ASTLuke Kanies2009-12-091-20/+35
| | | | | | | | | | | | | | | | | This commit extracts these three classes into a single ResourceType class in the Parser heirarchy, now completely independent of the AST heirarchy. Most of the other changes are just changing the interface to the new class, which is greatly simplified over the previous classes. This opens up the possibility of drastically simplifying a lot of this other code, too -- in particular, replacing the reference to the parser with a reference to the (soon to be renamed) LoadedCode class. Signed-off-by: Luke Kanies <luke@madstop.com>
* Fix #2638 - Allow creating several nodes with matching namesBrice Figureau2009-09-171-0/+4
| | | | | | | | When we are checking if a node exists before creating a new one we were also trying to match with regex node names, finding matches where in fact there is no equality. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* The first regex node now matches firstLuke Kanies2009-09-011-8/+15
| | | | | | | Before it was undefined, but now we always match the first defined node. Signed-off-by: Luke Kanies <luke@madstop.com>
* Implement node matching with regexesBrice Figureau2009-08-011-1/+9
| | | | | | | This patch enhance AST::HostName to support regexes, and modifies the parser to allow regex to be used as node name. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>]
* Make sure node are referenced by their namesBrice Figureau2009-08-011-2/+11
| | | | | | | | | This patch uses the unused AST::HostName as the only way to reference a node in the AST nodes array. The AST::HostName respect the hash properties of the underlying string, to keep the O(1) hash properties. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* Fix #2439 - let puppetdoc use loaded_codeBrice Figureau2009-07-241-0/+6
| | | | | | | | Since there isn't any unit test for puppetdoc rdoc code (my fault), nobody noticed it was using direct access to the parser AST array. This changeset fixes the way puppetdoc uses the parser results. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
* Adding a special class to handle loaded classes/defines/nodesLuke Kanies2009-07-051-0/+85
This class is extracted from the Parser class, and the main driver for it is to enable us to put mutexes around some of the hashes to see if they're the source of a race condition. Signed-off-by: Luke Kanies <luke@madstop.com>