#9363: load bug when last line of file begins with #
----------------------------+-----------------------------------------------
   Reporter:  mariah        |       Owner:  somebody  
       Type:  defect        |      Status:  new       
   Priority:  minor         |   Milestone:  sage-4.6.1
  Component:  misc          |    Keywords:            
     Author:  Mariah Lenox  |    Upstream:  N/A       
   Reviewer:                |      Merged:            
Work_issues:                |  
----------------------------+-----------------------------------------------

Comment(by wjp):

 The reason for this is likely this note from the python docs:

 {{{
 When compiling a string with multi-line code in
 'single' or 'eval' mode, input must be terminated
 by at least one newline character. This is to
 facilitate detection of incomplete and complete
 statements in the code module.
 }}}

 (Also note:
 {{{
 Changed in version 2.7: Allowed use of Windows and
 Mac newlines. Also input in 'exec' mode does not
 have to end in a newline anymore.
 }}}
 )

 The obvious patch would be to add a newline automatically before passing
 the input to {{{exec}}}. I'll create a patch for this.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/9363#comment:2>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" 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.com/group/sage-trac?hl=en.

Reply via email to