#1413: echoln overwrite symfony's echoln if sfYaml.php call first
-----------------------------------+----------------------------------------
 Reporter:  rande                  |       Owner:  jwage
     Type:  defect                 |      Status:  new  
 Priority:  minor                  |   Milestone:  New  
Component:  Attributes             |     Version:  0.11 
 Keywords:                         |    Has_test:  0    
 Mystatus:  Pending Core Response  |   Has_patch:  0    
-----------------------------------+----------------------------------------
 symfony has a echoln function so if doctrine's sfYaml is include first and
 then symfony sfYaml.class.php, the console output an error when executing
 : `./symfony doctrine:build-forms frontend`

 I post a quick patch, btw `echoln` is not used in doctrine code ...

 {{{
 Fatal error: Cannot redeclare echoln()
 (previously declared in
 /[...]/plugins/sfDoctrinePlugin/lib/doctrine/Doctrine/Parser/sfYaml.php:108)
 in /Users/rande/Projects/3rd/sf1.1.1/lib/yaml/sfYaml.class.php on line 104

 }}}

 {{{
 Index: sfYaml.php
 ===================================================================
 --- sfYaml.php  (revision 4867)
 +++ sfYaml.php  (working copy)
 @@ -103,9 +103,8 @@
   * @param string The string to echo with new line
   */
  //I add a is_callable test to avoid redeclaration.
 -if (!is_callable('echoln')){
 -  function echoln($string)
 -  {
 -    echo $string."\n";
 -  }
 -}
 \ No newline at end of file
 +
 +function doctrine_echoln($string)
 +{
 +  echo $string."\n";
 +}
 }}}

-- 
Ticket URL: <http://trac.doctrine-project.org/ticket/1413>
Doctrine <http://www.phpdoctrine.org>
PHP Doctrine Object Relational Mapper
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"doctrine-svn" group.
 To post to this group, send email to [email protected]
 To unsubscribe from this group, send email to [EMAIL PROTECTED]
 For more options, visit this group at 
http://groups.google.co.uk/group/doctrine-svn?hl=en-GB
-~----------~----~----~----~------~----~------~--~---

Reply via email to