Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Undefined method RootDoc::packageName() #50

Open
paulbarbu opened this issue Jul 7, 2011 · 1 comment
Open

Undefined method RootDoc::packageName() #50

paulbarbu opened this issue Jul 7, 2011 · 1 comment

Comments

@paulbarbu
Copy link

Whenever I try to generate my documentation for this project: https://github.com/paullik/yaCMS

I get the following error:
https://gist.github.com/1069566

I get that error just for my project, if I try to generate docs for your cloned phpdoctor it works well.
Here's my config: https://gist.github.com/1069578

The command I run: php phpdoc.php yacms.ini

PS:
This happens in both cases(if I use the archive or git clone)

@tetsuo13
Copy link
Contributor

I ran into the same issue. The problem is when declaring global constants using the const keyword, PHPDoctor treats this as a class constant and expects a class name to exist as the owner of the constant. This is partly because of an issue with token_get_all() (what PHPDoctor uses to tokenize) and how it parses -- though I reported it as bug #55447 and it was marked as bogus.

The gist you posted shows a problem in global_const.php and looking at the file I can see one constant being declared using the const keyword. A workaround for the time being would be to use define() for all global constants.

Ideally PHPDoctor would need to be modified to make a distinction for the const keyword when not found within a class definition.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants